ALT Linux Bugzilla
– Attachment 5902 Details for
Bug 29267
Не запускается, если /tmp и /var/tmp недоступны
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
use TMPDIR for PIPE path
LibreOffice4.patch (text/plain), 1.80 KB, created by
timonbl4@altlinux.org
on 2013-08-06 14:15:36 MSK
(
hide
)
Description:
use TMPDIR for PIPE path
Filename:
MIME Type:
Creator:
timonbl4@altlinux.org
Created:
2013-08-06 14:15:36 MSK
Size:
1.80 KB
patch
obsolete
>diff --git a/libreoffice/desktop/unx/source/start.c b/libreoffice/desktop/unx/source/start.c >index a488f95..5fa0d8e 100644 >--- a/libreoffice/desktop/unx/source/start.c >+++ b/libreoffice/desktop/unx/source/start.c >@@ -289,6 +289,7 @@ get_pipe_path( rtl_uString *pAppPath ) > rtlBootstrapHandle handle; > rtl_uString *pMd5hash = NULL; > sal_Unicode pUnicode[RTL_USTR_MAX_VALUEOFINT32]; >+ char *env_tmpdir; > > /* setup bootstrap filename */ > rtl_uString_newFromAscii( &pPath, "file://" ); >@@ -318,7 +319,10 @@ get_pipe_path( rtl_uString *pAppPath ) > if ( !pMd5hash ) > rtl_uString_new( &pMd5hash ); > >- if ( access( PIPEDEFAULTPATH, R_OK|W_OK ) == 0 ) >+ env_tmpdir = getenv("TMPDIR"); >+ if ( access( env_tmpdir, R_OK|W_OK ) == 0 ) >+ rtl_uString_newFromAscii( &pResult, env_tmpdir ); >+ else if ( access( PIPEDEFAULTPATH, R_OK|W_OK ) == 0 ) > rtl_uString_newFromAscii( &pResult, PIPEDEFAULTPATH ); > else > rtl_uString_newFromAscii( &pResult, PIPEALTERNATEPATH ); >diff --git a/libreoffice/sal/osl/unx/pipe.c b/libreoffice/sal/osl/unx/pipe.c >index f0f91da..731ec61 100644 >--- a/libreoffice/sal/osl/unx/pipe.c >+++ b/libreoffice/sal/osl/unx/pipe.c >@@ -187,13 +187,19 @@ oslPipe SAL_CALL osl_psz_createPipe(const sal_Char *pszPipeName, oslPipeOptions > int Flags; > size_t len; > struct sockaddr_un addr; >+ char *env_tmpdir; > > sal_Char name[PATH_MAX + 1]; > size_t nNameLength = 0; > int bNameTooLong = 0; > oslPipe pPipe; > >- if (access(PIPEDEFAULTPATH, R_OK|W_OK) == 0) >+ env_tmpdir = getenv("TMPDIR"); >+ if (access(env_tmpdir, R_OK|W_OK) == 0) >+ { >+ strncpy(name, env_tmpdir, sizeof(name)); >+ } >+ else if (access(PIPEDEFAULTPATH, R_OK|W_OK) == 0) > { > strncpy(name, PIPEDEFAULTPATH, sizeof(name)); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 29267
: 5902