Small modification of logs to make them R-compatible