Add argv[0] to args on standalone.
Fix Console.WriteLine to Dlog debug print out.
Change-Id: Iffc0eed1d0c7a9a538c12f9693b68e58011bea41
std::vector<char*> vargs;
- for (i=1; i<argc; i++)
+ for (i=0; i<argc; i++)
{
if (VersionOption.compare(argv[i]) == 0)
{
std::string approot;
if (appid != nullptr)
{
- approot = std::string(aul_get_app_root_path());
+ const char* approot_path = aul_get_app_root_path();
+ if (approot_path != nullptr)
+ {
+ approot = std::string(approot_path);
+ }
}
- else
+ if (approot.empty())
{
approot = Basename(standalonePath);
}
if (!string.IsNullOrEmpty(preloadDirectory))
{
- Console.WriteLine($"[{preloadDirectory}]");
+ ALog.Debug($"Load from [{preloadDirectory}]");
DirectoryInfo d = new DirectoryInfo(preloadDirectory);
if (Directory.Exists(d.FullName))
{
{
if (!string.IsNullOrEmpty(preloadDirectory))
{
- Console.WriteLine($"[{preloadDirectory}]");
+ ALog.Debug($"Load from [{preloadDirectory}]");
DirectoryInfo d = new DirectoryInfo(preloadDirectory);
if (Directory.Exists(d.FullName))
{