After end of work library does not finishing the process
mynoheart opened this issue · 4 comments
mynoheart commented
var Smb = require('smb2');
var client = new Smb({
share: '\\\\1.2.3.4\\Shared Folder',
domain: 'BlaBla',
username: '',
password: ''
});
client.readdir('subfolder', function (err, files) {
if (err) return new Error(err);
//error is null
console.log(files);
//the console output true list of files
//after this line process does not finishing
//it continues work about 5 seconds
});
If call more functions(ex. readdir,readfile and etc.) then work continues will be longer.
bchelli commented
Hi,
what kind of SMB server are you using ? Is it a Samba server ?
Have you tried with a share that does not contain a space ?
Thanks
mynoheart commented
Hello.
As smb server i used shared folder on Windows 7. I don't know smb server on Windows whether versions :-)
As client Linux.
No, it folder have free space.
Thanks.
mynoheart commented
Now i tried on localhost on Linux. Also process finished with delay. Samba 4.1.9-1
mynoheart commented
I'm sorry, i just forgot close the client connection after finish work. Problem is fixed. :-)