[PATCH] Usable Mac extensions stream name defines

Ralph Böhme rb at sernet.de
Mon Mar 10 10:52:18 MDT 2014


Hi

named streams support code cuts off the ":$DATA" part from stream
names when processing packets and storing the stream name in struct
smb_filename.stream_name.

Although the AFP stream name defines aren't used at all in master, I
preferred not to change the defines, but instead added seperate
defines without the ":$DATA" part.

Review appreciated. Thanks!
-Ralph

-- 
SerNet GmbH, Bahnhofsallee 1b, 37081 Göttingen
phone: +49-551-370000-0, fax: +49-551-370000-9
AG Göttingen, HRB 2816, GF: Dr. Johannes Loxen
http://www.sernet.de,mailto:kontakt@sernet.de
-------------- next part --------------
>From f8bae56ba0b804b1ed1ad993d7592d87b8e46c86 Mon Sep 17 00:00:00 2001
From: Ralph Boehme <rb at sernet.de>
Date: Mon, 13 Jan 2014 14:03:45 +0100
Subject: [PATCH 2/5] Add usable stream name defines

Add stream name defines that are usable with Samba's way of storing
stream names internally.

Signed-off-by: Ralph Boehme <rb at sernet.de>
---
 source3/include/MacExtensions.h | 17 ++++++++++++-----
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/source3/include/MacExtensions.h b/source3/include/MacExtensions.h
index 5e28725..a60f894 100644
--- a/source3/include/MacExtensions.h
+++ b/source3/include/MacExtensions.h
@@ -30,11 +30,18 @@
 #define DefaultStreamTestLen	6
 #define DefaultStreamTest		":$DATA"
 #define AFPDATA_STREAM 			"::$DATA"
-#define AFPINFO_STREAM 			":AFP_AfpInfo:$DATA"
-#define AFPRESOURCE_STREAM 		":AFP_Resource:$DATA"
-#define AFPCOMMENTS_STREAM 		":Comments:$DATA"
-#define AFPDESKTOP_STREAM 		":AFP_DeskTop:$DATA"
-#define AFPIDINDEX_STREAM 		":AFP_IdIndex:$DATA"
+
+#define AFPINFO_STREAM_NAME		":AFP_AfpInfo"
+#define AFPRESOURCE_STREAM_NAME		":AFP_Resource"
+#define AFPCOMMENTS_STREAM_NAME		":Comments"
+#define AFPDESKTOP_STREAM_NAME 		":AFP_DeskTop"
+#define AFPIDINDEX_STREAM_NAME 		":AFP_IdIndex"
+
+#define AFPINFO_STREAM 			AFPINFO_STREAM_NAME ":$DATA"
+#define AFPRESOURCE_STREAM 		AFPRESOURCE_STREAM_NAME ":$DATA"
+#define AFPCOMMENTS_STREAM 		AFPCOMMENTS_STREAM_NAME ":$DATA"
+#define AFPDESKTOP_STREAM 		AFPDESKTOP_STREAM_NAME ":$DATA"
+#define AFPIDINDEX_STREAM 		AFPIDINDEX_STREAM_NAME ":$DATA"
 
 /*
 ** NT's AFP_AfpInfo stream structure
-- 
1.8.5.3



More information about the samba-technical mailing list