git://scientific.zcu.cz
/
jra1mw.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b0a2792
)
fix bug #24088 - bad memory allocation when reading super users file
author
Aleš Křenek
<ljocha@ics.muni.cz>
Mon, 26 Feb 2007 11:53:08 +0000
(11:53 +0000)
committer
Aleš Křenek
<ljocha@ics.muni.cz>
Mon, 26 Feb 2007 11:53:08 +0000
(11:53 +0000)
org.glite.lb.server/src/bkserverd.c
patch
|
blob
|
blame
|
history
diff --git
a/org.glite.lb.server/src/bkserverd.c
b/org.glite.lb.server/src/bkserverd.c
index
0eab69f
..
45e8be3
100644
(file)
--- a/
org.glite.lb.server/src/bkserverd.c
+++ b/
org.glite.lb.server/src/bkserverd.c
@@
-1387,7
+1387,7
@@
static int read_roots(const char *file)
nl = strchr(buf,'\n');
if (nl) *nl = 0;
- super_users = realloc(super_users, (cnt+
1
) * sizeof super_users[0]);
+ super_users = realloc(super_users, (cnt+
2
) * sizeof super_users[0]);
super_users[cnt] = strdup(buf);
super_users[++cnt] = NULL;
}