From 824ba94fbe2e25efdd63e15342e14f4a9e078357 Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Sat, 20 May 2006 18:30:09 +0000 Subject: r15755: Fix Coverity bug # 294. Apparently password can be NULL, but cli_session_setup derefences it. Volker (This used to be commit b013b6908d22cfd38fcc56a9cb2ca675d75996d1) --- source3/libsmb/cliconnect.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source3/libsmb') diff --git a/source3/libsmb/cliconnect.c b/source3/libsmb/cliconnect.c index 2400f6ff1d..7f5b5d7fa5 100644 --- a/source3/libsmb/cliconnect.c +++ b/source3/libsmb/cliconnect.c @@ -1495,6 +1495,10 @@ NTSTATUS cli_full_connection(struct cli_state **output_cli, struct cli_state *cli = NULL; int pw_len = password ? strlen(password)+1 : 0; + if (password == NULL) { + password = ""; + } + nt_status = cli_start_connection(&cli, my_name, dest_host, dest_ip, port, signing_state, flags, retry); -- cgit