[SCM] Samba Shared Repository - branch master updated
Simo Sorce
idra at samba.org
Thu Apr 26 08:15:02 MDT 2012
The branch, master has been updated
via 1fbc185 replace: Fix use of mktemp
via 701fc99 addns: clean up headers
from 05456ac s3: Remove an unused variable
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
- Log -----------------------------------------------------------------
commit 1fbc18572543ed3056057df6ec4990278726fbf4
Author: Simo Sorce <idra at samba.org>
Date: Wed Apr 25 18:55:46 2012 -0400
replace: Fix use of mktemp
mktemp always returns the template, so checking for NULL doesn't cactch any
error. Errors are reported by turning the template into an empty string.
Autobuild-User: Simo Sorce <idra at samba.org>
Autobuild-Date: Thu Apr 26 16:14:24 CEST 2012 on sn-devel-104
commit 701fc995b75e392e896edc0c4314d758f7a5bee6
Author: Simo Sorce <idra at samba.org>
Date: Wed Apr 25 09:47:47 2012 -0400
addns: clean up headers
All this stuff is already included properly in the replace headers on top.
-----------------------------------------------------------------------
Summary of changes:
lib/addns/dns.h | 33 ---------------------------------
lib/replace/replace.c | 4 ++--
2 files changed, 2 insertions(+), 35 deletions(-)
Changeset truncated at 500 lines:
diff --git a/lib/addns/dns.h b/lib/addns/dns.h
index 88ba9d1..2e80577 100644
--- a/lib/addns/dns.h
+++ b/lib/addns/dns.h
@@ -38,47 +38,14 @@
#endif
#endif /* NO_CONFIG_H */
-#include <stdio.h>
-#include <stdlib.h>
#include <fcntl.h>
#include <time.h>
-#include <string.h>
-#include <errno.h>
#include <netdb.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <arpa/inet.h>
-#include <stdarg.h>
#ifdef HAVE_UUID_UUID_H
#include <uuid/uuid.h>
#endif
-#ifdef HAVE_KRB5_H
-#include <krb5.h>
-#endif
-
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-
-#ifndef int16
-#define int16 int16_t
-#endif
-
-#ifndef uint16
-#define uint16 uint16_t
-#endif
-
-#ifndef int32
-#define int32 int32_t
-#endif
-
-#ifndef uint32
-#define uint32 uint32_t
-#endif
-#endif
-
#include <talloc.h>
/*******************************************************************
diff --git a/lib/replace/replace.c b/lib/replace/replace.c
index c076ba1..322bf49 100644
--- a/lib/replace/replace.c
+++ b/lib/replace/replace.c
@@ -412,8 +412,8 @@ int rep_mkstemp(char *template)
{
/* have a reasonable go at emulating it. Hope that
the system mktemp() isn't completely hopeless */
- char *p = mktemp(template);
- if (!p)
+ mktemp(template);
+ if (template[0] == 0)
return -1;
return open(p, O_CREAT|O_EXCL|O_RDWR, 0600);
}
--
Samba Shared Repository
More information about the samba-cvs
mailing list