Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F141944017
D34819.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
654 B
Referenced Files
None
Subscribers
None
D34819.diff
View Options
diff --git a/sbin/ccdconfig/ccdconfig.c b/sbin/ccdconfig/ccdconfig.c
--- a/sbin/ccdconfig/ccdconfig.c
+++ b/sbin/ccdconfig/ccdconfig.c
@@ -288,6 +288,7 @@
char *cp, **argv;
int argc, rval;
gid_t egid;
+ char **nargv;
rval = 0;
egid = getegid();
@@ -315,11 +316,12 @@
for (cp = line; (cp = strtok(cp, " \t")) != NULL; cp = NULL) {
if (*cp == '#')
break;
- if ((argv = realloc(argv,
+ if ((nargv = realloc(argv,
sizeof(char *) * ++argc)) == NULL) {
warnx("no memory to configure ccds");
return (1);
}
+ argv = nargv;
argv[argc - 1] = cp;
/*
* If our action is to unconfigure all, then pass
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Jan 14, 9:56 PM (4 h, 58 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
27640005
Default Alt Text
D34819.diff (654 B)
Attached To
Mode
D34819: sbin/cddconfig: fix realloc
Attached
Detach File
Event Timeline
Log In to Comment