comparison toys/lsb/umount.c @ 1183:0752b2d58909 draft

Rename xmsprintf() to just xmprintf(). Partly because there's no supplied target string ala sprintf, and partly because I can never remember what order the m and s go in.
author Rob Landley <rob@landley.net>
date Thu, 16 Jan 2014 09:26:50 -0600
parents ac4a0cde89c2
children 4d898affda0c
comparison
equal deleted inserted replaced
1182:7079ea384a2e 1183:0752b2d58909
55 // Only add a comma if old string didn't end with one 55 // Only add a comma if old string didn't end with one
56 if (atold && *atold) { 56 if (atold && *atold) {
57 char *comma = ","; 57 char *comma = ",";
58 58
59 if (atold[strlen(atold)-1] == ',') comma = ""; 59 if (atold[strlen(atold)-1] == ',') comma = "";
60 temp = xmsprintf("%s%s%s", atold, comma, new); 60 temp = xmprintf("%s%s%s", atold, comma, new);
61 } else temp = xstrdup(new); 61 } else temp = xstrdup(new);
62 free (atold); 62 free (atold);
63 *old = temp; 63 *old = temp;
64 } 64 }
65 65