We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hello when i user the function smb_share_get_list, get the file list is inaccurate, it is the function bug or i used it invalied?
my code is: errcode_Typedef smb_listfile(const char *ip , char ***file_list , int *len) { struct in_addr addr; smb_session *session; smb_tid tid; smb_fd fd; int ret ; int i,j ; session = smb_session_new(); if (session == NULL) { printf("ERR_SESSION_NEW\n"); return ERR_SESSION_NEW; } inet_aton(ip, &addr);
if (smb_session_connect(session, "",addr.s_addr, SMB_TRANSPORT_TCP)) { printf("ERR_CONNECT\n"); return ERR_CONNECT; } smb_session_set_creds(session, "", "login", ""); ret = smb_session_login(session); if (ret) { printf("ERR_AUTH\n"); return ERR_AUTH; } ret = smb_share_get_list(session, file_list , len); if (ret) { printf("ERR_smb_share_get_list\n"); return ERR_AUTH; } smb_tree_disconnect(session, tid); smb_session_destroy(session); return CODE_OK;
}
int main(void) { char **list; int len , i;
printf("\n----------start list file-----------\n"); smb_listfile("10.44.53.88" , &list , &len); printf("len=%d\n", len); for(i = 0 ; i < len ; i++) { printf("%s\n",list[i] ); } smb_share_list_destroy(&list);
the print result is: len=3 share IPC$ ADMIN$
my real list is: a --floder aa--file ccc--file
what wrong?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
hello
when i user the function smb_share_get_list, get the file list is inaccurate, it is the function bug or i used it invalied?
my code is:
errcode_Typedef smb_listfile(const char *ip , char ***file_list , int *len)
{
struct in_addr addr;
smb_session *session;
smb_tid tid;
smb_fd fd;
int ret ;
int i,j ;
session = smb_session_new();
if (session == NULL)
{
printf("ERR_SESSION_NEW\n");
return ERR_SESSION_NEW;
}
inet_aton(ip, &addr);
}
int main(void)
{
char **list;
int len , i;
}
the print result is:
len=3
share
IPC$
ADMIN$
my real list is:
a --floder
aa--file
ccc--file
what wrong?
The text was updated successfully, but these errors were encountered: