openoffice-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yda...@apache.org
Subject svn commit: r1536093 - /openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx
Date Sun, 27 Oct 2013 11:04:33 GMT
Author: ydario
Date: Sun Oct 27 11:04:32 2013
New Revision: 1536093

URL: http://svn.apache.org/r1536093
Log:
i118923 - OS/2 port: remove three layer LIBPATH layout.

Modified:
    openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx

Modified: openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx
URL: http://svn.apache.org/viewvc/openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx?rev=1536093&r1=1536092&r2=1536093&view=diff
==============================================================================
--- openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx (original)
+++ openoffice/trunk/main/desktop/os2/source/applauncher/launcher.cxx Sun Oct 27 11:04:32
2013
@@ -42,12 +42,7 @@ int main( int argc, char* argv[])
 	erridErrorCode = WinGetLastError(hab);
 
 	// Calculate application name
-	CHAR	szLibpath[_MAX_PATH*2];
 	CHAR	szApplicationName[_MAX_PATH];
-	CHAR	szDrive[_MAX_PATH];
-	CHAR	szDir[_MAX_PATH];
-	CHAR	szFileName[_MAX_PATH];
-	CHAR	szExt[_MAX_PATH];
 
 	// get executable fullpath
 	DosGetInfoBlocks(NULL, &pib);
@@ -55,15 +50,13 @@ int main( int argc, char* argv[])
 	
 	// adjust libpath
 #if OSL_DEBUG_LEVEL > 0
+	CHAR	szLibpath[_MAX_PATH*2];
 	rc = DosQueryExtLIBPATH( (PSZ)szLibpath, BEGIN_LIBPATH);
 	fprintf( stderr, "1 BeginLibPath: %s\n", szLibpath);
 #endif
-	_splitpath( szApplicationName, szDrive, szDir, szFileName, szExt );
-	char* basedir = strstr( szDir, "\\PROGRAM\\");
+	char* basedir = strrchr( szApplicationName, '\\');
 	if (basedir) *basedir = 0;
- 	sprintf( szLibpath, "\"%s%s\\URE\\BIN\";\"%s%s\\BASIS\\PROGRAM\";%%BeginLIBPATH%%;",
-  		szDrive, szDir, szDrive, szDir);
-	DosSetExtLIBPATH( (PCSZ)szLibpath, BEGIN_LIBPATH);
+	DosSetExtLIBPATH( (PCSZ)szApplicationName, BEGIN_LIBPATH);
 
 	// make sure we load DLL from our path only, so multiple instances/versions
 	// can be loaded.
@@ -75,8 +68,7 @@ int main( int argc, char* argv[])
 #endif
 
 	// adjust exe name
-	_splitpath( szApplicationName, szDrive, szDir, szFileName, szExt );
-	_makepath( szApplicationName, szDrive, szDir, OFFICE_IMAGE_NAME, (".bin") );
+	strcat( szApplicationName, "\\" OFFICE_IMAGE_NAME ".bin");
 
 	// copy command line parameters
 	int i, len;



Mime
View raw message