[oe-commits] [meta-openembedded] 01/27: quagga: fix segment fault when stopping ospf6d

git at git.openembedded.org git at git.openembedded.org
Mon Feb 8 13:12:35 UTC 2016


martin_jansa pushed a commit to branch jethro-next
in repository meta-openembedded.

commit 50e09d1d3543a7fcd3d831d3ef30c13b3116fb1d
Author: Qi.Chen at windriver.com <Qi.Chen at windriver.com>
AuthorDate: Mon Nov 23 12:34:12 2015 +0800

    quagga: fix segment fault when stopping ospf6d
    
    In ospf6_clean, the variable ospf6 might be NULL causing segment fault
    when stopping ospf6d. Check the variable before referencing it.
    
    Signed-off-by: Chen Qi <Qi.Chen at windriver.com>
    Signed-off-by: Martin Jansa <Martin.Jansa at gmail.com>
    Signed-off-by: Joe MacDonald <joe_macdonald at mentor.com>
    Signed-off-by: Armin Kuster <akuster808 at gmail.com>
---
 ...heck-ospf6-before-using-it-in-ospf6_clean.patch | 28 ++++++++++++++++++++++
 .../recipes-protocols/quagga/quagga_0.99.24.1.bb   |  1 +
 2 files changed, 29 insertions(+)

diff --git a/meta-networking/recipes-protocols/quagga/files/0001-ospf6d-check-ospf6-before-using-it-in-ospf6_clean.patch b/meta-networking/recipes-protocols/quagga/files/0001-ospf6d-check-ospf6-before-using-it-in-ospf6_clean.patch
new file mode 100644
index 0000000..f08bb57
--- /dev/null
+++ b/meta-networking/recipes-protocols/quagga/files/0001-ospf6d-check-ospf6-before-using-it-in-ospf6_clean.patch
@@ -0,0 +1,28 @@
+Upstream-Status: Pending
+
+Subject: ospf6d: check ospf6 before using it in ospf6_clean
+
+The ospf6 variable might be 'NULL' causing segment fault error.
+Check it before referencing it.
+
+Signed-off-by: Chen Qi <Qi.Chen at windriver.com>
+---
+ ospf6d/ospf6d.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/ospf6d/ospf6d.c b/ospf6d/ospf6d.c
+index 3cdd5c1..e3bf1af 100644
+--- a/ospf6d/ospf6d.c
++++ b/ospf6d/ospf6d.c
+@@ -1892,6 +1892,8 @@ ospf6_init (void)
+ void
+ ospf6_clean (void)
+ {
++  if (ospf6 == NULL)
++    return;
+   if (ospf6->route_table)
+     ospf6_route_remove_all (ospf6->route_table);
+   if (ospf6->brouter_table)
+-- 
+1.9.1
+
diff --git a/meta-networking/recipes-protocols/quagga/quagga_0.99.24.1.bb b/meta-networking/recipes-protocols/quagga/quagga_0.99.24.1.bb
index 09c4e7d..cecf438 100644
--- a/meta-networking/recipes-protocols/quagga/quagga_0.99.24.1.bb
+++ b/meta-networking/recipes-protocols/quagga/quagga_0.99.24.1.bb
@@ -1,6 +1,7 @@
 require quagga.inc
 
 SRC_URI += "file://babel-close-the-stdout-stderr-as-in-other-daemons.patch \
+            file://0001-ospf6d-check-ospf6-before-using-it-in-ospf6_clean.patch \
 "
 
 SRC_URI[md5sum] = "7986bdc2fe6027d4c9216f7f5791e718"

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list