In reply to verific_engi:
Hard to say what might be wrong with so little code. I suggest interactive debugging setting a breakpoint on the call to read and stepping through the code.
In reply to verific_engi:
Hard to say what might be wrong with so little code. I suggest interactive debugging setting a breakpoint on the call to read and stepping through the code.