diff --git a/System/Shell/Commands/aplay.HC b/System/Shell/Commands/aplay.HC index 274c4b2..644e094 100644 --- a/System/Shell/Commands/aplay.HC +++ b/System/Shell/Commands/aplay.HC @@ -12,11 +12,10 @@ I64 @shell_cmd_aplay(@shell* sh, I64 argc, U8** argv) U8* filename = NULL; for (i = 1; i < argc; i++) { filename = @shell_expand_relative_path(sh, argv[i]); - System.Log(Fs, "filename: %s", filename); if (FileSystem.PathExists(filename)) { snd = Audio.SoundFromFile(filename); if (!snd) { - StrPrint(&buf, "%s: Error playing audio file\n", filename); + StrPrint(&buf, "%s: Error playing audio file\n", argv[i]); Stdio.WriteLine(sh, &buf); Free(filename); return 1; @@ -25,7 +24,7 @@ I64 @shell_cmd_aplay(@shell* sh, I64 argc, U8** argv) Audio.FreeSound(snd); Free(filename); } else { - StrPrint(&buf, "%s: No such file or directory\n", filename); + StrPrint(&buf, "%s: No such file or directory\n", argv[i]); Stdio.WriteLine(sh, &buf); Free(filename); return 1; diff --git a/System/Shell/Commands/cat.HC b/System/Shell/Commands/cat.HC index 50a4d0b..e1a5bee 100644 --- a/System/Shell/Commands/cat.HC +++ b/System/Shell/Commands/cat.HC @@ -32,7 +32,7 @@ I64 @shell_cmd_cat(@shell* sh, I64 argc, U8** argv) filename = @shell_expand_relative_path(sh, argv[i]); if (!FileSystem.PathExists(filename)) { res = 2; - StrPrint(&msg, "cat: cannot access '%s': No such file or directory\n", filename); + StrPrint(&msg, "cat: cannot access '%s': No such file or directory\n", argv[i]); Stdio.WriteLine(sh, &msg); } else { buf = FileSystem.ReadFile(filename, &size); diff --git a/System/Shell/Commands/ls.HC b/System/Shell/Commands/ls.HC index 4b19a44..7d9c7b6 100644 --- a/System/Shell/Commands/ls.HC +++ b/System/Shell/Commands/ls.HC @@ -6,7 +6,7 @@ I64 @shell_cmd_ls_output(@shell* sh, U8* arg_path, I64 flags) U8 buf[512]; U8* path = @shell_expand_relative_path(sh, arg_path); if (!FileSystem.PathExists(path)) { - StrPrint(&buf, "ls: cannot access '%s': No such file or directory\n", path); + StrPrint(&buf, "ls: cannot access '%s': No such file or directory\n", arg_path); Stdio.WriteLine(sh, &buf); Free(path); return 2;