r11502: make sure we always use the 7 chars for the unix socket name.
authorStefan Metzmacher <metze@samba.org>
Fri, 4 Nov 2005 08:02:20 +0000 (08:02 +0000)
committerGerald (Jerry) Carter <jerry@samba.org>
Wed, 10 Oct 2007 18:45:46 +0000 (13:45 -0500)
this is to test if that works on irix 6.4 where we can only use 16 chars for the sun_path
of the unix sockets.

the plan is to make multiple interfaces possible with socket wrapper,
and the format will change to ("%c%02X%04X", type, iface, port),
which is also 7 char to the file name

metze
(This used to be commit e60d491864ad7ea7f981bc1918ace4ee3fb2d77a)

source4/lib/socket_wrapper/socket_wrapper.c

index 1c3d5c3bfcb3663330d846f1ca24bf555518135e..d95806783d3187be394990db0e38d877796a9807 100644 (file)
@@ -63,7 +63,7 @@
    
    with this format we have 8 chars left for the directory name
 */
-#define SOCKET_FORMAT "%u_%u"
+#define SOCKET_FORMAT "%u_%05u"
 
 static struct sockaddr *sockaddr_dup(const void *data, socklen_t len)
 {