7 #include <libsmbclient.h>
8 #include "get_auth_data_fn.h"
11 int main(int argc, char * argv[])
26 smbc_init(get_auth_data_fn, debug);
30 fprintf(stdout, "Path: ");
32 fgets(path, sizeof(path) - 1, stdin);
33 if (strlen(path) == 0)
38 p = path + strlen(path) - 1;
44 if ((fd = smbc_open(path, O_RDONLY, 0)) < 0)
52 ret = smbc_read(fd, buffer, sizeof(buffer));
54 if (ret > 0) fwrite(buffer, 1, ret, stdout);