diff options
author | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-06-24 16:26:23 +1000 |
commit | 6da26870e0ae5acd6ff49a30ec2f6886b44d095e (patch) | |
tree | 850c71039563c16a5d563c47e7ba2ab645baf198 /source3/web | |
parent | 6925a799d04c6fa59dd2ddef1f5510f9bb7d17d1 (diff) | |
parent | 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 (diff) | |
download | samba-4.0.0alpha16.tar.gz samba-4.0.0alpha16.tar.xz samba-4.0.0alpha16.zip |
Merge 2610c05b5b95cc7036b3d6dfb894c6cfbdb68483 as Samba-4.0alpha16samba-4.0.0alpha16
Diffstat (limited to 'source3/web')
-rw-r--r-- | source3/web/cgi.c | 4 | ||||
-rw-r--r-- | source3/web/diagnose.c | 11 | ||||
-rw-r--r-- | source3/web/startstop.c | 2 | ||||
-rw-r--r-- | source3/web/swat.c | 4 |
4 files changed, 9 insertions, 12 deletions
diff --git a/source3/web/cgi.c b/source3/web/cgi.c index fa2304016ec..cc31eef97e5 100644 --- a/source3/web/cgi.c +++ b/source3/web/cgi.c @@ -118,7 +118,7 @@ void cgi_load_variables(void) #ifdef DEBUG_COMMENTS char dummy[100]=""; print_title(dummy); - d_printf("<!== Start dump in cgi_load_variables() %s ==>\n",__FILE__); + printf("<!== Start dump in cgi_load_variables() %s ==>\n",__FILE__); #endif if (!content_length) { @@ -275,7 +275,7 @@ static void cgi_setup_error(const char *err, const char *header, const char *inf } } - d_printf("HTTP/1.0 %s\r\n%sConnection: close\r\nContent-Type: text/html\r\n\r\n<HTML><HEAD><TITLE>%s</TITLE></HEAD><BODY><H1>%s</H1>%s<p></BODY></HTML>\r\n\r\n", err, header, err, err, info); + printf("HTTP/1.0 %s\r\n%sConnection: close\r\nContent-Type: text/html\r\n\r\n<HTML><HEAD><TITLE>%s</TITLE></HEAD><BODY><H1>%s</H1>%s<p></BODY></HTML>\r\n\r\n", err, header, err, err, info); fclose(stdin); fclose(stdout); exit(0); diff --git a/source3/web/diagnose.c b/source3/web/diagnose.c index cf93991f94c..abb4d79b9a7 100644 --- a/source3/web/diagnose.c +++ b/source3/web/diagnose.c @@ -20,6 +20,7 @@ #include "includes.h" #include "web/swat_proto.h" #include "lib/winbind_util.h" +#include "libsmb/libsmb.h" #ifdef WITH_WINBIND @@ -69,15 +70,11 @@ bool smbd_running(void) loopback_ip.s_addr = htonl(INADDR_LOOPBACK); in_addr_to_sockaddr_storage(&ss, loopback_ip); - if ((cli = cli_initialise()) == NULL) - return False; - - status = cli_connect(cli, global_myname(), &ss); + status = cli_connect_nb("localhost", &ss, 0, 0x20, lp_netbios_name(), + Undefined, &cli); if (!NT_STATUS_IS_OK(status)) { - cli_shutdown(cli); - return False; + return false; } - cli_shutdown(cli); return True; } diff --git a/source3/web/startstop.c b/source3/web/startstop.c index 81350e62f5c..e23acf89313 100644 --- a/source3/web/startstop.c +++ b/source3/web/startstop.c @@ -19,7 +19,7 @@ #include "includes.h" #include "web/swat_proto.h" -#include "dynconfig.h" +#include "dynconfig/dynconfig.h" /** Startup smbd from web interface. */ diff --git a/source3/web/swat.c b/source3/web/swat.c index f06bf5ed26c..277b25c4268 100644 --- a/source3/web/swat.c +++ b/source3/web/swat.c @@ -83,7 +83,7 @@ static char *fix_backslash(const char *str) return newstring; } -static const char *fix_quotes(TALLOC_CTX *ctx, const char *str) +static const char *fix_quotes(TALLOC_CTX *ctx, char *str) { char *newstring = NULL; char *p = NULL; @@ -101,7 +101,7 @@ static const char *fix_quotes(TALLOC_CTX *ctx, const char *str) } ++p; } - newstring = TALLOC_ARRAY(ctx, char, newstring_len); + newstring = talloc_array(ctx, char, newstring_len); if (!newstring) { return ""; } |