fix two small bugs in the hotplug2 rule parser (#2085)
authornbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Wed, 18 Jul 2007 07:23:40 +0000 (07:23 +0000)
committernbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Wed, 18 Jul 2007 07:23:40 +0000 (07:23 +0000)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@8023 3c298f89-4303-0410-b956-a3cf2f4a3e73

package/hotplug2/patches/110-parser_fixes.patch [new file with mode: 0644]

diff --git a/package/hotplug2/patches/110-parser_fixes.patch b/package/hotplug2/patches/110-parser_fixes.patch
new file mode 100644 (file)
index 0000000..0605ddd
--- /dev/null
@@ -0,0 +1,22 @@
+Index: hotplug2-0.9/rules.c
+===================================================================
+--- hotplug2-0.9.orig/rules.c  2007-07-18 09:15:38.968308540 +0200
++++ hotplug2-0.9/rules.c       2007-07-18 09:18:52.135316499 +0200
+@@ -756,6 +756,7 @@
+               ERROR("rules parse","Unable to parse rules file.");
+               return -1;
+       }
++      *return_rules = rules;
+       unmap_file(&filemap);
+@@ -997,7 +998,8 @@
+       
+       if (!terminate) {
+               /* A little bit hacky cleanup */
+-              return_rules->rules_c--;
++              if (!nested)
++                      return_rules->rules_c--;
+               return return_rules;
+       } else {
+               /*
This page took 0.024436 seconds and 4 git commands to generate.