2218N/AThis patch fixed segfault when supplying multiple options like '-f' for iftop.
2218N/AThe fixing has been integrated into open iftop-1.0 pre-release version. We can
2218N/Asee the fixing log here:
2218N/Ahttp://www.ex-parrot.com/~pdw/iftop/cvs/iftop/ChangeLog
2218N/A
2218N/A--- cfgfile.c.orig 2013-12-02 00:37:09.851645000 -0800
2218N/A+++ cfgfile.c 2013-12-02 00:31:53.734822000 -0800
2218N/A@@ -230,8 +230,13 @@
2218N/A stringmap S;
2218N/A
2218N/A S = stringmap_find(config, directive);
2218N/A- if (S) stringmap_delete_free(S);
2218N/A- stringmap_insert(config, directive, item_ptr(xstrdup(s)));
2218N/A+ if (S) {
2218N/A+ xfree(S->d.v);
2218N/A+ S->d = item_ptr(xstrdup(s));
2218N/A+ }
2218N/A+ else {
2218N/A+ stringmap_insert(config, directive, item_ptr(xstrdup(s)));
2218N/A+ }
2218N/A }
2218N/A
2218N/A int read_config(char *file, int whinge_on_error) {