aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Schmitt <scdbackup@gmx.net>2013-04-04 20:02:37 +0200
committerMatt Fleming <matt.fleming@intel.com>2013-04-25 14:59:08 +0100
commit5de463f724da515fd6c5ea49ded6dde178362181 (patch)
tree3f59be532b0df441d779b64d2ed3e071479ff0e8
parent1c96b61d4076b3821d855ddf589db80c18d59ee9 (diff)
downloadsyslinux-5de463f724da515fd6c5ea49ded6dde178362181.tar.gz
syslinux-5de463f724da515fd6c5ea49ded6dde178362181.tar.xz
syslinux-5de463f724da515fd6c5ea49ded6dde178362181.zip
iso9660.c did not copy terminating 0 of Rock Ridge namerockridge
I noticed that the trailing 0-byte is not copied to the result of iso_readdir(). The function iso_convert_name() does append a trailing 0.
-rw-r--r--core/fs/iso9660/iso9660.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/fs/iso9660/iso9660.c b/core/fs/iso9660/iso9660.c
index 0f7b3d2a..492adc65 100644
--- a/core/fs/iso9660/iso9660.c
+++ b/core/fs/iso9660/iso9660.c
@@ -240,7 +240,7 @@ static int iso_readdir(struct file *file, struct dirent *dirent)
/* Try to get Rock Ridge name */
ret = susp_rr_get_nm(fs, (char *) de, &rr_name, &name_len);
if (ret > 0) {
- memcpy(dirent->d_name, rr_name, name_len);
+ memcpy(dirent->d_name, rr_name, name_len + 1);
free(rr_name);
rr_name = NULL;
} else {