Skip to content

Commit

Permalink
TAG061 2023/06/24
Browse files Browse the repository at this point in the history
  Console:コンパイルエラーが発生した場合はリターンコード1で終了するように修正
  • Loading branch information
kumatan committed Jun 24, 2023
1 parent ee8b28e commit db4a8d0
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 7 deletions.
3 changes: 3 additions & 0 deletions CHANGE.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
�X�V����
TAG061 2023/06/24
Console:�R���p�C���G���[�����������ꍇ�̓��^�[���R�[�h�P�ŏI������悤�ɏC��

TAG060 2022/10/15
Compiler:�|���^�����g�̃f�B���C�l�𕄓_�t���̉����Ŏw�肷��ƃG���[���o��P�[�X������̂��C��

Expand Down
15 changes: 9 additions & 6 deletions PMDDotNETConsole/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Program
private static Common.Environment env = null;


static void Main(string[] args)
static int Main(string[] args)
{
Log.writeLine = WriteLine;
#if DEBUG
Expand All @@ -33,7 +33,7 @@ static void Main(string[] args)
if (args == null || args.Length-fnIndex < 1 )
{
WriteLine(LogLevel.ERROR, msg.get("E0600"));
return;
return 1;
}

try
Expand All @@ -42,17 +42,18 @@ static void Main(string[] args)
Encoding.RegisterProvider(CodePagesEncodingProvider.Instance);
#endif

Compile(args, fnIndex);
return Compile(args, fnIndex);

}
catch (Exception ex)
{
Log.WriteLine(LogLevel.FATAL, ex.Message);
Log.WriteLine(LogLevel.FATAL, ex.StackTrace);
return 1;
}
}

private static void Compile(string[] args,int argIndex)
private static int Compile(string[] args,int argIndex)
{
try
{
Expand Down Expand Up @@ -88,7 +89,7 @@ private static void Compile(string[] args,int argIndex)
if (string.IsNullOrEmpty(srcFile))
{
Log.WriteLine(LogLevel.ERROR, msg.get("E0601"));
return;
return 1;
}

byte[] ffFileBuf = null;
Expand Down Expand Up @@ -179,6 +180,7 @@ private static void Compile(string[] args,int argIndex)
File.WriteAllBytes(outfn, compiler.outFFFileBuf);
}
}
else return 1;
}

}
Expand Down Expand Up @@ -214,11 +216,12 @@ private static void Compile(string[] args,int argIndex)
{
Log.WriteLine(LogLevel.FATAL, ex.Message);
Log.WriteLine(LogLevel.FATAL, ex.StackTrace);
return 1;
}
finally
{
}

return 0;
}

private static Stream appendFileReaderCallback(string arg)
Expand Down
2 changes: 1 addition & 1 deletion PMDDotNETConsole/Properties/launchSettings.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"profiles": {
"PMDDotNETConsole": {
"commandName": "Project",
"commandLineArgs": "-LOGLEVEL=TRACE /V /c D:\\bootcamp\\FM音源\\data\\自作\\test\\testPMDポルタメント\\testPMDポルタメント.mml"
"commandLineArgs": "-LOGLEVEL=INFO /V /c C:\\Users\\kuma\\Downloads\\pmdtest.mml"
}
}
}
Binary file modified PMDDotNETPlayer/lib/MDSound.dll
Binary file not shown.
Binary file modified PMDDotNETPlayer/lib/RealChipCtlWrap.dll
Binary file not shown.
Binary file modified PMDDotNETPlayer/lib/fmgenmodule.dll
Binary file not shown.
Binary file modified PMDDotNETPlayer/lib/scci.dll
Binary file not shown.
Binary file modified lib/musicDriverInterface.dll
Binary file not shown.

0 comments on commit db4a8d0

Please sign in to comment.