summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/cdutils.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/cdutils.cpp b/lib/cdutils.cpp
index db302a7..d863927 100644
--- a/lib/cdutils.cpp
+++ b/lib/cdutils.cpp
@@ -564,7 +564,7 @@ struct cdutils::DirEntry * cdutils::find_dir_entry(Byte ** bufout, struct cdutil
if (!dir->R) {
ptr++;
} else {
- if (!strncmp(name.to_charp(), (char *) &(dir->id), dir->N)) {
+ if ((dir->N == name.strlen()) && (!strncmp(name.to_charp(), (char *) &(dir->id), dir->N))) {
rdir = dir;
}
ptr += dir->R;