c8ffd86 Prevent .history file corruption

Authored and Committed by Vojtech Vitek (V-Teq) 12 years ago
    Prevent .history file corruption
    
    - Implement file locking using shared readers, exclusive writer
      to prevent any .history file data corruption
    
    - Handle pending signals before flush so that the the .history file
      does not get truncated
    
    Resolves: #653054
    
        
file modified
+10 -0