1 #include <libsmbclient.h>
6 static void create_and_destroy_context (void)
10 ctx
= smbc_new_context ();
11 /* Both should do the same thing */
12 smbc_setOptionDebugToStderr(ctx
, 1);
13 smbc_option_set(ctx
, strdup("debug_to_stderr"), 1);
14 smbc_setDebug(ctx
, 1);
15 i
= smbc_getDebug(ctx
);
17 printf("smbc_getDebug() did not return debug level set\n");
20 if (!smbc_getOptionDebugToStderr(ctx
)) {
21 printf("smbc_setOptionDebugToStderr() did not stick\n");
24 smbc_init_context (ctx
);
25 smbc_free_context (ctx
, 1);
28 int main (int argc
, char **argv
)
30 create_and_destroy_context ();
31 create_and_destroy_context ();