
holmgren at lysator
Mar 24, 2007, 5:43 PM
Post #1 of 1
(1260 views)
Permalink
|
|
Infinite loop in spfquery.c:unimplemented()
|
|
There is a silly bug in unimplemented() that causes spfquery to enter an infinite loop if an unimplemented option is used. Nothing critical, but silly. This patch fixes it: diff -urNad libspf2-1.2.5.dfsg~/src/spfquery/spfquery.c libspf2-1.2.5.dfsg/src/spfquery/spfquery.c --- libspf2-1.2.5.dfsg~/src/spfquery/spfquery.c 2005-02-22 03:36:55.000000000 +0100 +++ libspf2-1.2.5.dfsg/src/spfquery/spfquery.c 2007-03-24 22:28:15.000000000 +0100 @@ -174,9 +174,7 @@ struct option *opt; int i; - i = 0; - opt = &long_options[i]; - while (opt->name) { + for (i = 0; (opt = &long_options[i])->name; i++) { if (flag == opt->val) { fprintf(stderr, "Unimplemented option: -%s or -%c\n", opt->name, flag); -- Magnus Holmgren holmgren [at] lysator (No Cc of list mail needed, thanks) "Exim is better at being younger, whereas sendmail is better for Scrabble (50 point bonus for clearing your rack)" -- Dave Evans ------- To unsubscribe, change your address, or temporarily deactivate your subscription, please go to http://v2.listbox.com/member/?list_id=1007
|