Bug 248701

Summary: Minicom consumes 100% CPU upon error on a serial device
Product: [Fedora] Fedora Reporter: Lubomir Kundrak <lkundrak>
Component: minicomAssignee: Miroslav Lichvar <mlichvar>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: low Docs Contact:
Priority: low    
Version: rawhideKeywords: EasyFix
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-07-25 13:40:42 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Fixes infinite loop in minicom when the serial adapter goes away none

Description Lubomir Kundrak 2007-07-18 11:42:50 UTC
Description of problem:

When something bad happens to a serial port device and operations on it
start returning failures, they are being ignored due to minicom's lack of
error checking.

Example of such failure is physical removal of the hardware. ioctl()s on the
gone adapter's filedescriptor will start returning failures which will get
ingored (and select() will return immediately without an complain) which will
result in an infinite loop.

Version-Release number of selected component (if applicable):

minicom-2.2-2.fc6

Steps to Reproduce:
1. Start minicom
2. Forcibly remove the device driver module, or the hardware
  
Actual results:

Minicom looping infinitely.

Expected results:

Exit with an error message.

Additional info:

I attach the diff of the change that fixed the problem for me.

Comment 1 Lubomir Kundrak 2007-07-18 11:42:50 UTC
Created attachment 159511 [details]
Fixes infinite loop in minicom when the serial adapter goes away

Comment 2 Miroslav Lichvar 2007-07-25 13:40:42 UTC
Should be fixed in minicom-2.2-3.fc8. Thanks for the report.