switch (ch) {
case 'a':
newprompt("Enter new email address: ", buf, 50);
- striplt(buf);
+ string_trim(buf);
if (!IsEmptyStr(buf)) {
// FIXME validate the email address (format, our own domain, addr does not belong to another user)
++num_recs;
return;
}
fgets(hbuf, SIZ, who);
+ if (hbuf[strlen(hbuf) - 1] == '\n') {
+ hbuf[strlen(hbuf) - 1] = 0;
+ }
pclose(who);
stripallbut(hbuf, '(', ')');
}