mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-02 22:55:26 +02:00
Handle empty names in CygPath.getFileName, bug 214603.
This commit is contained in:
parent
9284cb176d
commit
d4f3962b40
1 changed files with 5 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2000, 2007 QNX Software Systems and others.
|
||||
* Copyright (c) 2000, 2008 QNX Software Systems and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
|
@ -48,6 +48,10 @@ public class CygPath {
|
|||
}
|
||||
|
||||
public String getFileName(String name) throws IOException {
|
||||
// bug 214603, empty names don't create a response
|
||||
if (name == null || name.length() == 0)
|
||||
return name;
|
||||
|
||||
if (useOldCygPath) {
|
||||
return internalgetFileName(name);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue