Ignore empty recording directories in LocalRecorder.getRecordings()
This commit is contained in:
parent
528d7336e1
commit
17901901f9
|
@ -448,9 +448,14 @@ public class LocalRecorder implements Recorder {
|
|||
SimpleDateFormat sdf = new SimpleDateFormat(pattern);
|
||||
if (rec.isDirectory()) {
|
||||
try {
|
||||
// ignore directories, which are probably not created by ctbrec
|
||||
if (rec.getName().length() != pattern.length()) {
|
||||
continue;
|
||||
}
|
||||
// ignore empty directories
|
||||
if (rec.listFiles().length == 0) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Date startDate = sdf.parse(rec.getName());
|
||||
Recording recording = new Recording();
|
||||
|
|
Loading…
Reference in New Issue