diff options
author | Stefan Metzmacher <metze@samba.org> | 2009-02-04 08:50:46 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-02-05 17:48:06 +0100 |
commit | 5fbbddec353a9f809db549d21c16e5c9d9fbbd5b (patch) | |
tree | b347368e2aaa9f948ad079a0168beaf305f6ed1c /source4/ntvfs/posix/pvfs_rename.c | |
parent | 71d2287ec7740cf2089ddbef6991e7c3a80dcae0 (diff) | |
download | samba-5fbbddec353a9f809db549d21c16e5c9d9fbbd5b.tar.gz samba-5fbbddec353a9f809db549d21c16e5c9d9fbbd5b.tar.bz2 samba-5fbbddec353a9f809db549d21c16e5c9d9fbbd5b.zip |
s4:pvfs: fix some talloc related compiler warnings
metze
Diffstat (limited to 'source4/ntvfs/posix/pvfs_rename.c')
-rw-r--r-- | source4/ntvfs/posix/pvfs_rename.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source4/ntvfs/posix/pvfs_rename.c b/source4/ntvfs/posix/pvfs_rename.c index ed90bf3d7b..8001428122 100644 --- a/source4/ntvfs/posix/pvfs_rename.c +++ b/source4/ntvfs/posix/pvfs_rename.c @@ -103,7 +103,7 @@ static const char *pvfs_resolve_wildcard_component(TALLOC_CTX *mem_ctx, char *dest, *d; /* the length is bounded by the length of the two strings combined */ - dest = talloc_size(mem_ctx, strlen(fname) + strlen(pattern) + 1); + dest = talloc_array(mem_ctx, char, strlen(fname) + strlen(pattern) + 1); if (dest == NULL) { return NULL; } @@ -133,6 +133,8 @@ static const char *pvfs_resolve_wildcard_component(TALLOC_CTX *mem_ctx, *d = 0; + talloc_set_name_const(dest, dest); + return dest; } |