diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 1999-02-24 20:58:47 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 1999-02-24 20:58:47 +0000 |
commit | 3cf8394af5f646642df593c8de833441e186af64 (patch) | |
tree | 879804337835a352853d5eb06d31565d4dba33d7 /c/src/lib/libc/imfs_gtkn.c | |
parent | Moved mpc860.h around to make things compile. (diff) | |
download | rtems-3cf8394af5f646642df593c8de833441e186af64.tar.bz2 |
Changed IMFS to use IMFS_NAME_MAX as the maximum length of a basename
rather then NAME_MAX. NAME_MAX is 255 and that lets IMFS chew up memory
too fast. Perhaps in the future, the places in IMFS that put a maximum
length name string on the stack and the jnode structure does not include
a maximu length name string can be fixed so this is not a problem.
Diffstat (limited to 'c/src/lib/libc/imfs_gtkn.c')
-rw-r--r-- | c/src/lib/libc/imfs_gtkn.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/c/src/lib/libc/imfs_gtkn.c b/c/src/lib/libc/imfs_gtkn.c index 052c67ceba..aa63841725 100644 --- a/c/src/lib/libc/imfs_gtkn.c +++ b/c/src/lib/libc/imfs_gtkn.c @@ -32,11 +32,11 @@ IMFS_token_types IMFS_get_token( * Copy a name into token. (Remember NULL is a token.) */ - while ( !IMFS_is_separator( path[i] ) && (i <= NAME_MAX) ) { + while ( !IMFS_is_separator( path[i] ) && (i <= IMFS_NAME_MAX) ) { token[i] = path[i]; - if (i == NAME_MAX) + if (i == IMFS_NAME_MAX) return IMFS_INVALID_TOKEN; if ( !IMFS_is_valid_name_char( token[i] ) ) |