X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0d598bae33dff0e48eebd569aa3d75e95e8d6947..c7426f4ca3ca80554c6360f7385741e971a96af3:/src/os2/utils.cpp diff --git a/src/os2/utils.cpp b/src/os2/utils.cpp index 1ee5362ef4..a2f9dafe5a 100644 --- a/src/os2/utils.cpp +++ b/src/os2/utils.cpp @@ -160,9 +160,9 @@ bool wxShell( SData.FgBg = SSF_FGBG_FORE; SData.TraceOpt = SSF_TRACEOPT_NONE; SData.PgmTitle = PgmTitle; - SData.PgmName = zShell; + SData.PgmName = (char*)zShell; - sInputs = "/C " + rCommand; + sInputs = _T("/C ") + rCommand; SData.PgmInputs = (BYTE*)sInputs.c_str(); SData.TermQ = 0; SData.Environment = 0; @@ -231,6 +231,12 @@ wxMemorySize wxGetFreeMemory() return (wxMemorySize)lSize; } +// Get Process ID +unsigned long wxGetProcessId() +{ + return (unsigned long)getpid(); +} + // ---------------------------------------------------------------------------- // env vars // ---------------------------------------------------------------------------- @@ -410,7 +416,7 @@ const wxChar* wxGetHomeDir( # define MAX_PATH 256 #endif - const wxChar *szHome = wxGetenv("HOME"); + const wxChar *szHome = wxGetenv((wxChar*)"HOME"); if ( szHome == NULL ) { // we're homeless, use current directory. rStrDir = wxT("."); @@ -429,7 +435,7 @@ wxChar* wxGetUserHome ( wxChar* zHome; wxString sUser1(rUser); - char *wxBuffer = new wxChar[256]; + wxChar *wxBuffer = new wxChar[256]; #ifndef __EMX__ if (!sUser1.empty()) { @@ -465,7 +471,7 @@ wxChar* wxGetUserHome ( } } delete[] wxBuffer; - return NULL; // No home known! + return (wxChar*)wxEmptyString; // No home known! } wxString WXDLLEXPORT wxPMErrorToStr(