summaryrefslogtreecommitdiff
path: root/sal/osl/unx
diff options
context:
space:
mode:
authorOliver Braun <obr@openoffice.org>2000-10-30 10:56:26 +0000
committerOliver Braun <obr@openoffice.org>2000-10-30 10:56:26 +0000
commit22b87ee2fb3b54ae56fab9fd6a301d5da3a8d802 (patch)
treefab54d2bb7aeeee1b96c62f5b3b024fb548c18e4 /sal/osl/unx
parent823b3a21f2a6330d21c68684aaf44005fe176707 (diff)
removed SUPD dependencies
Diffstat (limited to 'sal/osl/unx')
-rw-r--r--sal/osl/unx/profile.c56
1 files changed, 11 insertions, 45 deletions
diff --git a/sal/osl/unx/profile.c b/sal/osl/unx/profile.c
index 46ab34856087..b83c39bb9baa 100644
--- a/sal/osl/unx/profile.c
+++ b/sal/osl/unx/profile.c
@@ -2,9 +2,9 @@
*
* $RCSfile: profile.c,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 15:17:21 $
+ * last change: $Author: obr $ $Date: 2000-10-30 11:56:26 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -2593,7 +2593,6 @@ static sal_Bool lookupProfile(const sal_Char *pszPath, const sal_Char *pszFile,
sal_Char Path[PATH_MAX] = "";
sal_Char Product[132] = "";
sal_Char Buffer[1024] = "";
- sal_Char szSUPD[20] = "";
if (*pszPath == '"')
{
@@ -2808,53 +2807,20 @@ static sal_Bool lookupProfile(const sal_Char *pszPath, const sal_Char *pszFile,
if ((osl_psz_getProfileName(SVERSION_LOCATION, SVERSION_NAME, Profile, sizeof(Profile))) &&
(hProfile = osl_psz_openProfile(Profile, osl_Profile_READLOCK)))
{
- pChr = &Product[strlen(Product)];
-
- /* append build number */
- strcat(Product, "/");
- snprintf(szSUPD, sizeof(szSUPD), "%li", osl_getSUPD());
- strcat(Product, szSUPD);
-
- osl_readProfileString(hProfile, SVERSION_SECTION, Product,
- Buffer, sizeof(Buffer), "");
+ osl_readProfileString(hProfile, SVERSION_SECTION, Product, Buffer, sizeof(Buffer), "");
+ osl_closeProfile(hProfile);
- /* if not found, try it without build number */
- if (strlen(Buffer) <= 0)
+ /* if not found, try the fallback */
+ if ((strlen(Buffer) <= 0) && (strcmp(SVERSION_LOCATION, SVERSION_FALLBACK) != 0))
{
- *pChr = '\0';
-
- osl_readProfileString(hProfile, SVERSION_SECTION, Product,
- Buffer, sizeof(Buffer), "");
-
- osl_closeProfile(hProfile);
-
- /* if not found, try the fallback */
- if ((strlen(Buffer) <= 0) && (strcmp(SVERSION_LOCATION, SVERSION_FALLBACK) != 0))
+ if ((osl_psz_getProfileName(SVERSION_FALLBACK, SVERSION_NAME, Profile, sizeof(Profile))) &&
+ (hProfile = osl_psz_openProfile(Profile, osl_Profile_READLOCK)))
{
- if ((osl_psz_getProfileName(SVERSION_FALLBACK, SVERSION_NAME, Profile, sizeof(Profile))) &&
- (hProfile = osl_psz_openProfile(Profile, osl_Profile_READLOCK)))
- {
- /* prepare build number */
- *pChr = '/';
-
- osl_readProfileString(hProfile, SVERSION_SECTION, Product,
- Buffer, sizeof(Buffer), "");
-
- /* if not found, try it without build number */
- if (strlen(Buffer) <= 0)
- {
- *pChr = '\0';
-
- osl_readProfileString(hProfile, SVERSION_SECTION, Product,
- Buffer, sizeof(Buffer), "");
- }
-
- osl_closeProfile(hProfile);
- }
+ osl_readProfileString(hProfile, SVERSION_SECTION, Product, Buffer, sizeof(Buffer), "");
}
- }
- else
+
osl_closeProfile(hProfile);
+ }
if (strlen(Buffer) > 0)
{