2
0
mirror of https://github.com/sudo-project/sudo.git synced 2025-08-31 14:25:15 +00:00

kill perror("malloc") since we already have a good error messages

pw_ent -> pw for brevity
This commit is contained in:
Todd C. Miller
1998-11-04 01:39:18 +00:00
parent b751a2b9c4
commit de21acbb37
3 changed files with 46 additions and 57 deletions

View File

@@ -125,7 +125,7 @@ void load_interfaces()
for (;;) {
ifconf_buf = ifconf_buf ? realloc(ifconf_buf, len) : malloc(len);
if (ifconf_buf == NULL) {
perror("malloc");
(void) fprintf(stderr, "%s: cannot allocate memory!\n", Argv[0]);
exit(1);
}
ifconf = (struct ifconf *) ifconf_buf;
@@ -159,7 +159,6 @@ void load_interfaces()
*/
interfaces = (struct interface *) malloc(sizeof(struct interface) * n);
if (interfaces == NULL) {
perror("malloc");
(void) fprintf(stderr, "%s: cannot allocate memory!\n", Argv[0]);
exit(1);
}