lib/cms_scanner/helper.rb in cms_scanner-0.0.40.3 vs lib/cms_scanner/helper.rb in cms_scanner-0.0.41.0
- old
+ new
@@ -1,9 +1,8 @@
# @param [ String ] file The file path
def redirect_output_to_file(file)
$stdout.reopen(file, 'w')
$stdout.sync = true
- $stderr.reopen($stdout) # Not sure if this is needed
end
# @return [ Integer ] The memory of the current process in Bytes
def memory_usage
`ps -o rss= -p #{Process.pid}`.to_i * 1024 # ps returns the value in KB