diff options
author | Volker Lendecke <vlendec@samba.org> | 2007-09-04 10:15:04 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:30:29 -0500 |
commit | ff0947fbed841065fce85c64ff4b2a2e8f24f056 (patch) | |
tree | df5c9cadb1d89cc0ee6b5fdf712743443b209d7c /source3/registry | |
parent | faefb22c61568c678476b4dad36bdc5ce3afb499 (diff) | |
download | samba-ff0947fbed841065fce85c64ff4b2a2e8f24f056.tar.gz samba-ff0947fbed841065fce85c64ff4b2a2e8f24f056.tar.bz2 samba-ff0947fbed841065fce85c64ff4b2a2e8f24f056.zip |
r24949: Remove some static buffers
(This used to be commit df648d47ff3c4e24f439fda839653bda98323100)
Diffstat (limited to 'source3/registry')
-rw-r--r-- | source3/registry/reg_objects.c | 4 | ||||
-rw-r--r-- | source3/registry/reg_perfcount.c | 4 | ||||
-rw-r--r-- | source3/registry/reg_util.c | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/source3/registry/reg_objects.c b/source3/registry/reg_objects.c index aebf0142ee..f759a921d2 100644 --- a/source3/registry/reg_objects.c +++ b/source3/registry/reg_objects.c @@ -439,9 +439,9 @@ uint32 regval_dword( REGISTRY_VALUE *val ) char* regval_sz( REGISTRY_VALUE *val ) { - static pstring data; + pstring data; rpcstr_pull( data, regval_data_p(val), sizeof(data), regval_size(val), 0 ); - return data; + return talloc_strdup(talloc_tos(), data); } diff --git a/source3/registry/reg_perfcount.c b/source3/registry/reg_perfcount.c index dec57a5ec7..ce67b68a83 100644 --- a/source3/registry/reg_perfcount.c +++ b/source3/registry/reg_perfcount.c @@ -37,7 +37,7 @@ PERF_OBJECT_TYPE *_reg_perfcount_find_obj(PERF_DATA_BLOCK *block, int objind); static char* counters_directory( const char *dbname ) { - static pstring fname; + pstring fname; fstring path; if ( !dbname ) @@ -47,7 +47,7 @@ static char* counters_directory( const char *dbname ) pstrcpy( fname, lock_path( path ) ); - return fname; + return talloc_strdup(talloc_tos(), fname); } /********************************************************************* diff --git a/source3/registry/reg_util.c b/source3/registry/reg_util.c index 75050c1850..703ad7cb57 100644 --- a/source3/registry/reg_util.c +++ b/source3/registry/reg_util.c @@ -102,7 +102,7 @@ void normalize_reg_path( pstring keyname ) char* reg_remaining_path( const char *key ) { - static pstring new_path; + pstring new_path; char *p; if ( !key || !*key ) @@ -121,7 +121,7 @@ char* reg_remaining_path( const char *key ) else p++; - return p; + return talloc_strdup(talloc_tos(), p); } /********************************************************************** |