cbebber13 / cdmaworkshoptool

Automatically exported from code.google.com/p/cdmaworkshoptool
1 stars 0 forks source link

selecting wrong port causes force close #4

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Refresh the com ports 
2. select wrong com port
3. program stops running 

What is the expected output? What do you see instead?
Program should output something along the lines error non usb/qc serial port

What version of the product are you using? On what operating system?
alpha version 2.7 and beta version 2. Windows 7 64 bit.

Please provide any additional information below.

Original issue reported on code.google.com by MrRobert...@gmail.com on 2 Oct 2012 at 2:11

GoogleCodeExporter commented 8 years ago
I do agree this is an issue, I believe it is related or a duplicate of issue #1 
though.

The basic problem is this:
-p/invoke code is used to create a serial port 'handle' instead of basic .net 
SerialPort type because the .net Type does not support BlackBerry's reported 
handle type
-managed code makes an attempt to call the unmanaged code which(im guessing 
since I have not debugged the unmanaged part) either gets hung 'forever' 
waiting for an end-of-line character, or gets hung forever trying to read a 
response that is not there

I think the fix would involve more specific management of the thread which 
calls out to p/invoke, however I am not certain the best way to achieve this... 
I may try asking on stackoverflow

Original comment by chromableedstudios on 5 Oct 2012 at 1:21