Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
34a66ff5
Kaydet (Commit)
34a66ff5
authored
Kas 10, 2015
tarafından
Stephan Bergmann
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
loplugin:nullptr (automatic rewrite)
Change-Id: Ie7e4b028ee0cd6e0254dda8dfe3c70973865bc03
üst
7cb9fce0
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
14 additions
and
14 deletions
+14
-14
bootstrapfixturebase.cxx
unotest/source/cpp/bootstrapfixturebase.cxx
+2
-2
filters-test.cxx
unotest/source/cpp/filters-test.cxx
+3
-3
getargument.cxx
unotest/source/cpp/getargument.cxx
+1
-1
officeconnection.cxx
unotest/source/cpp/officeconnection.cxx
+7
-7
uniquepipename.cxx
unotest/source/cpp/uniquepipename.cxx
+1
-1
No files found.
unotest/source/cpp/bootstrapfixturebase.cxx
Dosyayı görüntüle @
34a66ff5
...
...
@@ -45,9 +45,9 @@ test::BootstrapFixtureBase::BootstrapFixtureBase()
{
#ifndef ANDROID
const
char
*
pSrcRoot
=
getenv
(
"SRC_ROOT"
);
CPPUNIT_ASSERT_MESSAGE
(
"SRC_ROOT env variable not set"
,
pSrcRoot
!=
NULL
&&
pSrcRoot
[
0
]
!=
0
);
CPPUNIT_ASSERT_MESSAGE
(
"SRC_ROOT env variable not set"
,
pSrcRoot
!=
nullptr
&&
pSrcRoot
[
0
]
!=
0
);
const
char
*
pWorkdirRoot
=
getenv
(
"WORKDIR_FOR_BUILD"
);
CPPUNIT_ASSERT_MESSAGE
(
"$WORKDIR_FOR_BUILD env variable not set"
,
pWorkdirRoot
!=
NULL
&&
pWorkdirRoot
[
0
]
!=
0
);
CPPUNIT_ASSERT_MESSAGE
(
"$WORKDIR_FOR_BUILD env variable not set"
,
pWorkdirRoot
!=
nullptr
&&
pWorkdirRoot
[
0
]
!=
0
);
#else
const
char
*
pSrcRoot
=
"/assets"
;
const
char
*
pWorkdirRoot
=
"/assets"
;
...
...
unotest/source/cpp/filters-test.cxx
Dosyayı görüntüle @
34a66ff5
...
...
@@ -23,12 +23,12 @@ namespace test {
void
decode
(
const
OUString
&
rIn
,
const
OUString
&
rOut
)
{
rtlCipher
cipher
=
rtl_cipher_create
(
rtl_Cipher_AlgorithmARCFOUR
,
rtl_Cipher_ModeStream
);
CPPUNIT_ASSERT_MESSAGE
(
"cipher creation failed"
,
cipher
!=
0
);
CPPUNIT_ASSERT_MESSAGE
(
"cipher creation failed"
,
cipher
!=
nullptr
);
//mcrypt --bare -a arcfour -o hex -k 435645 -s 3
const
sal_uInt8
aKey
[
3
]
=
{
'C'
,
'V'
,
'E'
};
rtlCipherError
result
=
rtl_cipher_init
(
cipher
,
rtl_Cipher_DirectionDecode
,
aKey
,
SAL_N_ELEMENTS
(
aKey
),
0
,
0
);
rtlCipherError
result
=
rtl_cipher_init
(
cipher
,
rtl_Cipher_DirectionDecode
,
aKey
,
SAL_N_ELEMENTS
(
aKey
),
nullptr
,
0
);
CPPUNIT_ASSERT_EQUAL_MESSAGE
(
"cipher init failed"
,
rtl_Cipher_E_None
,
result
);
...
...
@@ -111,7 +111,7 @@ void FiltersTest::recursiveScan(filterStatus nExpected,
OUString
realUrl
;
if
(
bEncrypted
)
{
CPPUNIT_ASSERT_EQUAL
(
osl
::
FileBase
::
E_None
,
osl
::
FileBase
::
createTempFile
(
NULL
,
NULL
,
&
sTmpFile
));
CPPUNIT_ASSERT_EQUAL
(
osl
::
FileBase
::
E_None
,
osl
::
FileBase
::
createTempFile
(
nullptr
,
nullptr
,
&
sTmpFile
));
decode
(
sURL
,
sTmpFile
);
realUrl
=
sTmpFile
;
}
...
...
unotest/source/cpp/getargument.cxx
Dosyayı görüntüle @
34a66ff5
...
...
@@ -31,7 +31,7 @@ namespace test {
namespace
detail
{
bool
getArgument
(
OUString
const
&
name
,
OUString
*
value
)
{
OSL_ASSERT
(
value
!=
0
);
OSL_ASSERT
(
value
!=
nullptr
);
return
rtl
::
Bootstrap
::
get
(
"arg-"
+
name
,
*
value
);
}
...
...
unotest/source/cpp/officeconnection.cxx
Dosyayı görüntüle @
34a66ff5
...
...
@@ -38,7 +38,7 @@
namespace
test
{
OfficeConnection
::
OfficeConnection
()
:
process_
(
0
)
{}
OfficeConnection
::
OfficeConnection
()
:
process_
(
nullptr
)
{}
OfficeConnection
::~
OfficeConnection
()
{}
...
...
@@ -72,7 +72,7 @@ void OfficeConnection::setUp() {
noquickArg
.
pData
,
norestoreArg
.
pData
,
nologoArg
.
pData
,
headlessArg
.
pData
,
acceptArg
.
pData
,
userArg
.
pData
,
jreArg
.
pData
,
classpathArg
.
pData
};
rtl_uString
**
envs
=
0
;
rtl_uString
**
envs
=
nullptr
;
OUString
argEnv
;
if
(
detail
::
getArgument
(
"env"
,
&
argEnv
))
{
...
...
@@ -84,7 +84,7 @@ void OfficeConnection::setUp() {
osl_executeProcess
(
toAbsoluteFileUrl
(
argSoffice
.
copy
(
RTL_CONSTASCII_LENGTH
(
"path:"
))).
pData
,
args
,
SAL_N_ELEMENTS
(
args
),
0
,
0
,
0
,
envs
,
envs
==
0
?
0
:
1
,
args
,
SAL_N_ELEMENTS
(
args
),
0
,
nullptr
,
nullptr
,
envs
,
envs
==
nullptr
?
0
:
1
,
&
process_
));
}
else
if
(
argSoffice
.
match
(
"connect:"
))
{
desc
=
argSoffice
.
copy
(
RTL_CONSTASCII_LENGTH
(
"connect:"
));
...
...
@@ -102,7 +102,7 @@ void OfficeConnection::setUp() {
css
::
uno
::
UNO_QUERY_THROW
);
break
;
}
catch
(
css
::
connection
::
NoConnectException
&
)
{}
if
(
process_
!=
0
)
{
if
(
process_
!=
nullptr
)
{
TimeValue
delay
=
{
1
,
0
};
// 1 sec
CPPUNIT_ASSERT_EQUAL
(
osl_Process_E_TimedOut
,
...
...
@@ -112,7 +112,7 @@ void OfficeConnection::setUp() {
}
void
OfficeConnection
::
tearDown
()
{
if
(
process_
!=
0
)
{
if
(
process_
!=
nullptr
)
{
if
(
context_
.
is
())
{
css
::
uno
::
Reference
<
css
::
frame
::
XDesktop2
>
desktop
=
css
::
frame
::
Desktop
::
create
(
context_
);
context_
.
clear
();
...
...
@@ -131,13 +131,13 @@ void OfficeConnection::tearDown() {
osl_getProcessInfo
(
process_
,
osl_Process_EXITCODE
,
&
info
));
CPPUNIT_ASSERT_EQUAL
(
oslProcessExitCode
(
0
),
info
.
Code
);
osl_freeProcessHandle
(
process_
);
process_
=
0
;
// guard against subsequent calls to isStillAlive
process_
=
nullptr
;
// guard against subsequent calls to isStillAlive
}
}
bool
OfficeConnection
::
isStillAlive
()
const
{
if
(
process_
==
0
)
{
if
(
process_
==
nullptr
)
{
// In case "soffice" argument starts with "connect:" we have no direct
// control over the liveness of the soffice.bin process (would need to
// directly monitor the bridge) so can only assume the best here:
...
...
unotest/source/cpp/uniquepipename.cxx
Dosyayı görüntüle @
34a66ff5
...
...
@@ -31,7 +31,7 @@ OUString uniquePipeName(OUString const & name) {
info
.
Size
=
sizeof
info
;
CPPUNIT_ASSERT_EQUAL
(
osl_Process_E_None
,
osl_getProcessInfo
(
0
,
osl_Process_IDENTIFIER
,
&
info
));
osl_getProcessInfo
(
nullptr
,
osl_Process_IDENTIFIER
,
&
info
));
return
name
+
OUString
::
number
(
info
.
Ident
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment