Article 58574 reading keyboard

reading keyboard

by
rac8006
from LinuxQuestions.org on (#58574)
I have a program that opens and read a character from the keyboard. If the keyboard is connected to a KVM when the keyboard switches to the another PC. My program get an error no device. So I can close the file. But what is the best way to determine that the keyboard has returned.
Do I loop trying to open the device? Is ther a way to determine that the keyboard is back?

Thankslatest?d=yIl2AUoC8zA latest?i=uTH6lL7ABRk:ez1v3RjcYgg:F7zBnMy latest?i=uTH6lL7ABRk:ez1v3RjcYgg:V_sGLiP latest?d=qj6IDK7rITs latest?i=uTH6lL7ABRk:ez1v3RjcYgg:gIN9vFwuTH6lL7ABRk
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments