projects
/
kopensolaris-gnu
/
glibc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2326de1
)
(generate_guard): Avoid extra allocation and the resulting leak.
author
drepper
<drepper>
Fri, 7 Apr 2006 03:03:14 +0000
(
03:03
+0000)
committer
drepper
<drepper>
Fri, 7 Apr 2006 03:03:14 +0000
(
03:03
+0000)
sunrpc/rpc_main.c
patch
|
blob
|
history
diff --git
a/sunrpc/rpc_main.c
b/sunrpc/rpc_main.c
index
0ddda83
..
028ee01
100644
(file)
--- a/
sunrpc/rpc_main.c
+++ b/
sunrpc/rpc_main.c
@@
-531,7
+531,7
@@
generate_guard (const char *pathname)
filename = strrchr (pathname, '/'); /* find last component */
filename = ((filename == NULL) ? pathname : filename + 1);
- guard =
strdup (filename
);
+ guard =
extendfile (filename, "_H_RPCGEN"
);
/* convert to upper case */
tmp = guard;
while (*tmp)
@@
-541,7
+541,6
@@
generate_guard (const char *pathname)
tmp++;
}
- guard = extendfile (guard, "_H_RPCGEN");
return guard;
}