s3:libsmb: always init cli->{server_os,server_domain,server_type}
[samba.git] / source3 / libsmb / clientgen.c
index db980a486db7a20adb724af0224dab180d97ae52..bc544afd32476dd839e643867d68b22920957dbd 100644 (file)
@@ -190,6 +190,19 @@ struct cli_state *cli_state_create(TALLOC_CTX *mem_ctx,
                return NULL;
        }
 
+       cli->server_domain = talloc_strdup(cli, "");
+       if (!cli->server_domain) {
+               goto error;
+       }
+       cli->server_os = talloc_strdup(cli, "");
+       if (!cli->server_os) {
+               goto error;
+       }
+       cli->server_type = talloc_strdup(cli, "");
+       if (!cli->server_type) {
+               goto error;
+       }
+
        cli->dfs_mountpoint = talloc_strdup(cli, "");
        if (!cli->dfs_mountpoint) {
                goto error;