From 6a9e446f8ed6f6be43335d87563b94cbab2c4cd4 Mon Sep 17 00:00:00 2001 From: Pierre Ossman Date: Tue, 16 Oct 2018 16:10:37 +0200 Subject: [PATCH] Avoid : in recording file names That character is not legal in Windows file names, so make sure we avoid it when creating recording files. --- other/js/websockify.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/other/js/websockify.js b/other/js/websockify.js index 9564447..4a8d033 100755 --- a/other/js/websockify.js +++ b/other/js/websockify.js @@ -39,7 +39,7 @@ new_client = function(client, req) { log('Version ' + client.protocolVersion + ', subprotocol: ' + client.protocol); if (argv.record) { - var rs = fs.createWriteStream(argv.record + '/' + new Date().toISOString()); + var rs = fs.createWriteStream(argv.record + '/' + new Date().toISOString().replace(/:/g, "_")); rs.write('var VNC_frame_data = [\n'); } else { var rs = null;