From: Ralph Corderoy Date: Sun, 27 Aug 2017 11:13:39 +0000 (+0100) Subject: Replace add(foo, NULL) with mh_xstrdup(foo). X-Git-Url: https://diplodocus.org/git/nmh/commitdiff_plain/9e4dbc2d5379b96a8d90e28cf8fce803d6cc1ff4?hp=9e4dbc2d5379b96a8d90e28cf8fce803d6cc1ff4 Replace add(foo, NULL) with mh_xstrdup(foo). add()'s arguments are back to front so add(foo, bar) produces bar+foo in the normal case. Thus add(foo, NULL) is read as the jarring NULL+foo. Removing the NULL with mh_xstrdup() avoids this. FENDNULL is used when it isn't obvious foo can't be NULL as add() treats it as "" in that case. ---