| 371 |
} |
} |
| 372 |
for (int i = 0; i < newfiles.length; i++) { |
for (int i = 0; i < newfiles.length; i++) { |
| 373 |
FTPFile file = newfiles[i]; |
FTPFile file = newfiles[i]; |
| 374 |
if (!file.getName().equals(".") |
if (file != null |
| 375 |
|
&& !file.getName().equals(".") |
| 376 |
&& !file.getName().equals("..")) { |
&& !file.getName().equals("..")) { |
| 377 |
if (isFunctioningAsDirectory(ftp, dir, file)) { |
if (isFunctioningAsDirectory(ftp, dir, file)) { |
| 378 |
String name = vpath + file.getName(); |
String name = vpath + file.getName(); |
| 572 |
boolean candidateFound = false; |
boolean candidateFound = false; |
| 573 |
String target = null; |
String target = null; |
| 574 |
for (int icounter = 0; icounter < array.length; icounter++) { |
for (int icounter = 0; icounter < array.length; icounter++) { |
| 575 |
if (array[icounter].isDirectory()) { |
if (array[icounter] != null && array[icounter].isDirectory()) { |
| 576 |
if (!array[icounter].getName().equals(".") |
if (!array[icounter].getName().equals(".") |
| 577 |
&& !array[icounter].getName().equals("..")) { |
&& !array[icounter].getName().equals("..")) { |
| 578 |
candidateFound = true; |
candidateFound = true; |
| 581 |
+ target + " where a directory called " + array[icounter].getName() |
+ target + " where a directory called " + array[icounter].getName() |
| 582 |
+ " exists", Project.MSG_DEBUG); |
+ " exists", Project.MSG_DEBUG); |
| 583 |
for (int pcounter = 0; pcounter < array.length; pcounter++) { |
for (int pcounter = 0; pcounter < array.length; pcounter++) { |
| 584 |
if (array[pcounter].getName().equals(target) && pcounter != icounter) { |
if (array[pcounter] != null && pcounter != icounter && target.equals(array[pcounter].getName()) ) { |
| 585 |
candidateFound = false; |
candidateFound = false; |
| 586 |
} |
} |
| 587 |
} |
} |
| 720 |
return null; |
return null; |
| 721 |
} |
} |
| 722 |
for (int icounter = 0; icounter < theFiles.length; icounter++) { |
for (int icounter = 0; icounter < theFiles.length; icounter++) { |
| 723 |
if (theFiles[icounter].getName().equalsIgnoreCase(soughtPathElement)) { |
if (theFiles[icounter] != null && theFiles[icounter].getName().equalsIgnoreCase(soughtPathElement)) { |
| 724 |
return theFiles[icounter].getName(); |
return theFiles[icounter].getName(); |
| 725 |
} |
} |
| 726 |
} |
} |
| 842 |
return null; |
return null; |
| 843 |
} |
} |
| 844 |
for (int fcount = 0; fcount < theFiles.length; fcount++) { |
for (int fcount = 0; fcount < theFiles.length; fcount++) { |
| 845 |
|
if (theFiles[fcount] != null) { |
| 846 |
if (theFiles[fcount].getName().equals(lastpathelement)) { |
if (theFiles[fcount].getName().equals(lastpathelement)) { |
| 847 |
return theFiles[fcount]; |
return theFiles[fcount]; |
| 848 |
} else if (!isCaseSensitive() |
} else if (!isCaseSensitive() |
| 849 |
&& theFiles[fcount].getName().equalsIgnoreCase(lastpathelement)) { |
&& theFiles[fcount].getName().equalsIgnoreCase( |
| 850 |
|
lastpathelement)) { |
| 851 |
return theFiles[fcount]; |
return theFiles[fcount]; |
| 852 |
} |
} |
| 853 |
} |
} |
| 854 |
|
} |
| 855 |
return null; |
return null; |
| 856 |
} |
} |
| 857 |
/** |
/** |
| 1829 |
String fileName = localFile.getName(); |
String fileName = localFile.getName(); |
| 1830 |
boolean found = false; |
boolean found = false; |
| 1831 |
try { |
try { |
| 1832 |
if (counter == 1) { |
if (theFiles == null) { |
| 1833 |
theFiles = ftp.listFiles(); |
theFiles = ftp.listFiles(); |
| 1834 |
} |
} |
| 1835 |
for (int counter2 = 0; counter2 < theFiles.length; counter2++) { |
for (int counter2 = 0; counter2 < theFiles.length; counter2++) { |
| 1836 |
if (theFiles[counter2].getName().equals(fileName)) { |
if (theFiles[counter2] != null && theFiles[counter2].getName().equals(fileName)) { |
| 1837 |
found = true; |
found = true; |
| 1838 |
break; |
break; |
| 1839 |
} |
} |