This is the mail archive of the
binutils@sourceware.org
mailing list for the binutils project.
PATCH: PR binutils/5713: strings: use '-0' as option will meet infinite loop
- From: "H.J. Lu" <hjl dot tools at gmail dot com>
- To: binutils at sources dot redhat dot com
- Date: Fri, 8 Feb 2008 12:54:02 -0800
- Subject: PATCH: PR binutils/5713: strings: use '-0' as option will meet infinite loop
string_min == 0 will make strings go into an infinite loop. I am
checking it in as an obvious fix.
H.J.
---
2008-02-08 H.J. Lu <hongjiu.lu@intel.com>
PR binutils/5713
* strings.c (main): Set string_min to 4 if it is <= 0.
--- binutils/strings.c.zero 2008-01-25 09:01:03.000000000 -0800
+++ binutils/strings.c 2008-02-08 12:49:22.000000000 -0800
@@ -270,7 +270,7 @@ main (int argc, char **argv)
}
}
- if (string_min < 0)
+ if (string_min <= 0)
string_min = 4;
switch (encoding)