summaryrefslogtreecommitdiffstats
path: root/source3/libsmb/clistr.c
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2009-03-17 14:04:43 +1100
committerAndrew Bartlett <abartlet@samba.org>2009-04-14 12:11:00 +1000
commit4786a493f70070dce6de4cbe488c9de1bdbb75ad (patch)
treea568260a9cf5d255674d0e31dddf4f5e3644e0da /source3/libsmb/clistr.c
parent41e4f12c482082d6e622d1fdc830e38853cdbd8b (diff)
downloadsamba-4786a493f70070dce6de4cbe488c9de1bdbb75ad.tar.gz
samba-4786a493f70070dce6de4cbe488c9de1bdbb75ad.tar.xz
samba-4786a493f70070dce6de4cbe488c9de1bdbb75ad.zip
Solve some of the conflict between Samba3 and Samba4 push_string
This renames push_string in Samba3 into push_string_base and push_string_check for the two different use cases. This should allow push_string to be imported from Samba4, using it's calling conventions.
Diffstat (limited to 'source3/libsmb/clistr.c')
-rw-r--r--source3/libsmb/clistr.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/source3/libsmb/clistr.c b/source3/libsmb/clistr.c
index 86857814043..1f296ebd099 100644
--- a/source3/libsmb/clistr.c
+++ b/source3/libsmb/clistr.c
@@ -32,21 +32,23 @@ size_t clistr_push_fn(const char *function,
if (dest_len == -1) {
if (((ptrdiff_t)dest < (ptrdiff_t)cli->outbuf) || (buf_used > cli->bufsize)) {
DEBUG(0, ("Pushing string of 'unlimited' length into non-SMB buffer!\n"));
- return push_string_fn(function, line,
- cli->outbuf,
- SVAL(cli->outbuf, smb_flg2),
- dest, src, -1, flags);
+ return push_string_base(function, line,
+ cli->outbuf,
+ SVAL(cli->outbuf, smb_flg2),
+ dest, src, -1, flags);
}
- return push_string_fn(function, line, cli->outbuf,
- SVAL(cli->outbuf, smb_flg2),
- dest, src, cli->bufsize - buf_used,
- flags);
+ return push_string_base(function, line,
+ cli->outbuf,
+ SVAL(cli->outbuf, smb_flg2),
+ dest, src, cli->bufsize - buf_used,
+ flags);
}
/* 'normal' push into size-specified buffer */
- return push_string_fn(function, line, cli->outbuf,
- SVAL(cli->outbuf, smb_flg2),
- dest, src, dest_len, flags);
+ return push_string_base(function, line,
+ cli->outbuf,
+ SVAL(cli->outbuf, smb_flg2),
+ dest, src, dest_len, flags);
}
size_t clistr_pull_fn(const char *function,