Delete corrupt session files.
This commit is contained in:
parent
e6837fb79b
commit
6433f7faee
1 changed files with 2 additions and 0 deletions
|
@ -1,4 +1,5 @@
|
|||
require 'json'
|
||||
require 'rss'
|
||||
|
||||
module Session
|
||||
|
||||
|
@ -73,6 +74,7 @@ module Session
|
|||
data = Marshal.load( all )
|
||||
}
|
||||
rescue Exception => e
|
||||
File.delete(session_file)
|
||||
puts "Error reading '#{session_file}':"
|
||||
puts e.inspect
|
||||
return
|
||||
|
|
Loading…
Reference in a new issue