summaryrefslogtreecommitdiff
path: root/source3/utils
diff options
context:
space:
mode:
authorVolker Lendecke <vl@sernet.de>2007-11-24 16:32:38 +0100
committerJeremy Allison <jra@samba.org>2007-11-24 18:11:11 -0800
commit5c6f96144706ceb4f7fd3a5515dcebf78b21c908 (patch)
treec70d1a2049a9eec576cc874f2d0b7786dd7c50fe /source3/utils
parentd2c2635a280b1bfbbcd52fa96bbeff3f60672c45 (diff)
downloadsamba-5c6f96144706ceb4f7fd3a5515dcebf78b21c908.tar.gz
samba-5c6f96144706ceb4f7fd3a5515dcebf78b21c908.tar.bz2
samba-5c6f96144706ceb4f7fd3a5515dcebf78b21c908.zip
Remove a static
(This used to be commit 85a84f72ffc440fb71744cb72de2dba07793123c)
Diffstat (limited to 'source3/utils')
-rw-r--r--source3/utils/net_usershare.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source3/utils/net_usershare.c b/source3/utils/net_usershare.c
index 658c0089da..19fa8fad2f 100644
--- a/source3/utils/net_usershare.c
+++ b/source3/utils/net_usershare.c
@@ -41,7 +41,7 @@ struct {
static const char *get_us_error_code(enum usershare_err us_err)
{
- static pstring out;
+ char *result;
int idx = 0;
while (us_errs[idx].us_errstr != NULL) {
@@ -51,8 +51,10 @@ static const char *get_us_error_code(enum usershare_err us_err)
idx++;
}
- slprintf(out, sizeof(out), "Usershare error code (0x%x)", (unsigned int)us_err);
- return out;
+ result = talloc_asprintf(talloc_tos(), "Usershare error code (0x%x)",
+ (unsigned int)us_err);
+ SMB_ASSERT(result != NULL);
+ return result;
}
/* The help subsystem for the USERSHARE subcommand */