codemaker: fix invalid string index access
Change-Id: Icca819484e751864d146a893fe78e8ef2c36363b
This commit is contained in:
@@ -87,8 +87,9 @@ OString createFileNameFromType( const OString& destination,
|
|||||||
length += prefix.getLength() + type.getLength() + postfix.getLength();
|
length += prefix.getLength() + type.getLength() + postfix.getLength();
|
||||||
|
|
||||||
sal_Bool withSeparator = sal_False;
|
sal_Bool withSeparator = sal_False;
|
||||||
if (destination[destination.getLength()] != '\\' &&
|
if (!destination.isEmpty() &&
|
||||||
destination[destination.getLength()] != '/' &&
|
destination[destination.getLength() - 1] != '\\' &&
|
||||||
|
destination[destination.getLength() - 1] != '/' &&
|
||||||
type[0] != '\\' &&
|
type[0] != '\\' &&
|
||||||
type[0] != '/')
|
type[0] != '/')
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user