Open mrvik opened 4 years ago
Hey, thanks for your bugreport. I have an example smb explorer app in the tree, I moved it into 'cmd/smb/main.go` now. Could you please check if that also crashes in the same way? Please check https://github.com/mvo5/libsmbclient-go/blob/master/cmd/smb/main.go#L54 for an example usage. maybe the issue is that you use an anonymous func(). But it's ~5y since I wrote this code so I'm a bit rusty :) I kind of abandoned it after I found that libsmbclient is not thread safe at all.
Fwiw - with the example in main.go I don't get crashes.
Fwiw - with the example in main.go I don't get crashes.
Yes, this annoyed me at first, I tried to copy your fn from https://github.com/mvo5/libsmbclient-go/blob/master/cmd/smb/main.go#L54 and pass it instead of my anon function and it worked.
Seems like anon functions aren't working (not related to GC nor goroutine thread locking as far as I tested). The real issue seems anon functions definitively, I'm updating the title
Thanks for your fast reply.
Hey, after writing some code, seems like there is a problem on the SetAuthCallback function.
Stack trace:
Go code: