From b33658bc611537db87144c0b9b677b6271e0bec8 Mon Sep 17 00:00:00 2001 From: yura Date: Fri, 17 Nov 2006 22:51:29 +0000 Subject: [PATCH] cleanups --- libntfs/dir.c | 2 +- libntfs/unistr.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libntfs/dir.c b/libntfs/dir.c index 3468500f..c6b562f1 100644 --- a/libntfs/dir.c +++ b/libntfs/dir.c @@ -522,7 +522,7 @@ ntfs_inode *ntfs_pathname_to_inode(ntfs_volume *vol, ntfs_inode *parent, p = ascii; /* Remove leading /'s. */ - while (p && *p && *p == PATH_SEP) + while (p && *p == PATH_SEP) p++; while (p && *p) { /* Find the end of the first token. */ diff --git a/libntfs/unistr.c b/libntfs/unistr.c index 8ed054e9..9f802674 100644 --- a/libntfs/unistr.c +++ b/libntfs/unistr.c @@ -727,7 +727,7 @@ ntfschar *ntfs_str2ucs(const char *s, int *len) ntfs_log_perror("Couldn't convert '%s' to Unicode", s); return NULL; } - if (*len > 0xff) { + if (*len > NTFS_MAX_NAME_LEN) { free(ucs); errno = ENAMETOOLONG; return NULL;