diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-02-02 15:17:52 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-02-02 15:17:52 +0100 |
commit | 5595ee701eab0fef0683c93e3c99788ab1b08520 (patch) | |
tree | f65921d6b5b0c8c988fa37eb4dc57e2879d25bf2 /basic | |
parent | 19c0eff34a5e1de4f3aff723b7750d4e01d4ba6d (diff) |
loplugin:useuniqueptr
Change-Id: I3a246a22baaac8195dc1b94c42994de7d80e8336
Diffstat (limited to 'basic')
-rw-r--r-- | basic/source/runtime/methods.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/basic/source/runtime/methods.cxx b/basic/source/runtime/methods.cxx index 1a4c12b4f1bb..3447bff32949 100644 --- a/basic/source/runtime/methods.cxx +++ b/basic/source/runtime/methods.cxx @@ -419,7 +419,7 @@ RTLFUNC(CurDir) } } } - char* pBuffer = new char[ _MAX_PATH ]; + char pBuffer[ _MAX_PATH ]; if ( _getdcwd( nCurDir, pBuffer, _MAX_PATH ) != nullptr ) { rPar.Get(0)->PutString( OUString::createFromAscii( pBuffer ) ); @@ -428,7 +428,6 @@ RTLFUNC(CurDir) { StarBASIC::Error( ERRCODE_BASIC_NO_DEVICE ); } - delete [] pBuffer; #else |