search for: smbc_readdir

Displaying 4 results from an estimated 4 matches for "smbc_readdir".

Did you mean: smb_readdir
2007 Aug 21
3
Segment violation during the list of directory with smbc_readdir
..."error initializing libsmbclient: %s\n", strerror(errno)); return -1; } if((smbdh = smbc_opendir(smb_url)) < 1) { fprintf(stderr,"Unable to open directory: %s", strerror(errno)); return -1; } while((smbdi = smbc_readdir(smbdh)) != NULL) { fprintf(stderr, "%s\n", smbdi->name); } printf("DONE\n"); return 0; } The listed folder contains a file with a very long Japanese name. The next call of smbc_readdir after this file is listed crashes: . .. New Text Document.txt s...
2009 Feb 04
1
libsmbclient: readdir caches dirents?
I'm using libsmbclient with smbc contexts. If I do an smbc_readdir() of a directory X then I get a bunch of (correct) dirents. I then smbc_rmdir() a subdirectory X/Y, which succeeds. A subsequent smbc_readdir(), using the same smbc context, still gives a dirent for X/Y. I've observed this with libsmbclient from Samba 3.2.4, 3.2.7 and 3.3.0, talking to Samba...
2002 Nov 29
0
libsmbclient problem
.... */ if( smbc_init( auth_func, 10 ) < 0 ) { perror( "smbc_init" ); return 1; } /* open directory */ handle = smbc_opendir( smburl ); if( handle < 0 ) { perror( "smbc_opendir" ); return 1; } /* read dir contents */ errno = 0; while( (dirp=smbc_readdir( handle )) != NULL ) { printf( "%s\n", dirp->name ); } if( errno != 0 ) { perror( "smbc_readdir" ); smbc_closedir( handle ); return 1; } printf( "Done.\n" ); /* close dir */ smbc_closedir( handle ); return 0; }
2007 May 10
2
programming libsmbclient
hi all, I have a strange problem using the libsmbclient api.. retrieving or stating files named with percents in is for some of them impossible. Example: a file located at "smb://test/test/%7C2.txt" cannot be retrieved with my code, smbc_open fails with the code NT_STATUS_OBJECT_NAME_INVALID. I am not sure but, url encoding/decoding that would escape strings with "percent"