summaryrefslogtreecommitdiffstats
path: root/source3/include/srvstr.h
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2007-07-13 01:22:09 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:28:35 -0500
commite8dc2ea03d212bc4b4facc2a900f6a443365c390 (patch)
treec418222494cb9cd05250f30b8f6671e0b3046fa3 /source3/include/srvstr.h
parent79a9f6dcb86703fd48d1321e50ff2b678ce39664 (diff)
downloadsamba-e8dc2ea03d212bc4b4facc2a900f6a443365c390.tar.gz
samba-e8dc2ea03d212bc4b4facc2a900f6a443365c390.tar.xz
samba-e8dc2ea03d212bc4b4facc2a900f6a443365c390.zip
r23858: Added srvstr_pull_buf_talloc() and srvstr_pull_talloc()
calls and converted reply_tcon and reply_tconX to use them - to show the boilerplate usage (valgrind tested). In conjunction with Volker's srvstr_get_path_talloc() work this should allow us to start eliminating all pstrings/fstrings out of the main path processing code. I'll watch the build farm tonight... Jeremy. (This used to be commit b4eff3f68089f082781afcf90d43faa317949566)
Diffstat (limited to 'source3/include/srvstr.h')
-rw-r--r--source3/include/srvstr.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/source3/include/srvstr.h b/source3/include/srvstr.h
index c1bb5226e5c..588a807f64b 100644
--- a/source3/include/srvstr.h
+++ b/source3/include/srvstr.h
@@ -20,6 +20,10 @@
#define srvstr_pull(base_ptr, smb_flags2, dest, src, dest_len, src_len, flags) \
pull_string(base_ptr, smb_flags2, dest, src, dest_len, src_len, flags)
+/* talloc version of above. */
+#define srvstr_pull_talloc(ctx, base_ptr, smb_flags2, dest, src, src_len, flags) \
+ pull_string_talloc(ctx, base_ptr, smb_flags2, dest, src, src_len, flags)
+
/* pull a string from the smb_buf part of a packet. In this case the
string can either be null terminated or it can be terminated by the
end of the smbbuf area
@@ -28,3 +32,6 @@
#define srvstr_pull_buf(inbuf, smb_flags2, dest, src, dest_len, flags) \
pull_string(inbuf, smb_flags2, dest, src, dest_len, smb_bufrem(inbuf, src), flags)
+/* talloc version of above. */
+#define srvstr_pull_buf_talloc(ctx, inbuf, smb_flags2, dest, src, flags) \
+ pull_string_talloc(ctx, inbuf, smb_flags2, dest, src, smb_bufrem(inbuf, src), flags)