Skip to content
New issue

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

win10, run libusbTest.exe, crash, report "Unhandled exception thrown: write access violation. entry->next was nullptr.". #9

Open
hiquokka opened this issue Sep 30, 2020 · 0 comments

Comments

@hiquokka
Copy link

     hi, i comipler the lastest code( 10.0.19042.541, vs2019 16.7.4,  ZPL Priter: USB\VID_1FC9&PID_2016\

or USB\VID_154F&PID_1300), except modifyed the vid && pid of ZPL Printer. then it crashed. tpis is: Unhandled exception thrown: write access violation. entry->next was nullptr.
Detail:
Call Stack:

LibusbTest.exe!list_del(list_head * entry) Line 203 C
LibusbTest.exe!handle_event_trigger(libusb_context * ctx) Line 2116 C
LibusbTest.exe!handle_events(libusb_context * ctx, timeval * tv) Line 2234 C
LibusbTest.exe!libusb_handle_events_timeout_completed(libusb_context * ctx, timeval * tv, int * completed) Line 2341 C
LibusbTest.exe!libusb_handle_events_completed(libusb_context * ctx, int * completed) Line 2440 C
LibusbTest.exe!LibUSB::TransferImpl::Start() Line 155 C++
LibusbTest.exe!LibUSB::Transfer::Start() Line 122 C++
LibusbTest.exe!main(int argc, char * * argv) Line 114 C++
[External Code]
kernel32.dll![Frames below may be incorrect and/or missing, no symbols loaded for kernel32.dll] Unknown

debug the code, it stop at(libusbi.h): entry->next->prev = entry->prev; context is :
static inline void list_del(struct list_head *entry)
{
entry->next->prev = entry->prev;
entry->prev->next = entry->next;
entry->next = entry->prev = NULL;
}

   finally,  i mean, i known this problem is not caused by your library, but libusb.  
   running at win32 platform,  if someone run the exe which added the libusb wrapper DLL file(like your project libusbTest.exe) ,

the exe crashed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant