hedgewars/uVideoRec.pas
changeset 14914 66b510a8b81c
parent 14908 a414d37278df
child 14935 9ab78e08a34c
--- a/hedgewars/uVideoRec.pas	Mon May 06 22:43:35 2019 +0200
+++ b/hedgewars/uVideoRec.pas	Mon May 06 23:03:16 2019 +0200
@@ -83,7 +83,7 @@
 
 {$IOCHECKS OFF}
     // open file with prerecorded camera positions
-    filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtin';
+    filename:= shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix) + '.txtin';
     Assign(cameraFile, filename);
     Reset(cameraFile, SizeOf(TFrame));
     maxProgress:= FileSize(cameraFile);
@@ -113,11 +113,11 @@
         desc:= desc + 'Theme: ' + Theme + #10;
     desc:= desc + 'prefix[' + RecPrefix + ']prefix';
 
-    filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix;
+    filename:= shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix);
 
     recordAudio:= (cAudioCodec <> 'no');
     if recordAudio then
-        soundFilePath:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.sw'
+        soundFilePath:= shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix) + '.sw'
     else
         soundFilePath:= '';
 
@@ -285,7 +285,7 @@
     begin
         if GameType <> gmtDemo then // this is save and game demo is not recording, abort
             exit;
-        CopyFile(recordFileName, UserPathPrefix + '/VideoTemp/' + RecPrefix + '.hwd');
+        CopyFile(recordFileName, shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix) + '.hwd');
     end;
 
     if cIsSoundEnabled then
@@ -301,7 +301,7 @@
 
 {$IOCHECKS OFF}
         // create sound file
-        filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.sw';
+        filename:= shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix) + '.sw';
         Assign(audioFile, filename);
         Rewrite(audioFile, 1);
         if IOResult <> 0 then
@@ -312,7 +312,7 @@
         end;
 
     // create file with camera positions
-    filename:= UserPathPrefix + '/VideoTemp/' + RecPrefix + '.txtout';
+    filename:= shortstring(UserPathPrefix) + '/VideoTemp/' + shortstring(RecPrefix) + '.txtout';
     Assign(cameraFile, filename);
     Rewrite(cameraFile, SizeOf(TFrame));
     if IOResult <> 0 then