diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2008-06-10 22:03:34 +0000 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2008-06-10 22:03:34 +0000 |
commit | 68b00fd1be95b3ee5f962bf7d624c61875d8db86 (patch) | |
tree | d3e2b6ece79fa20d1bbb0dfcbc3ec329ec0e8b8d /console | |
parent | 9c4205108f5c97e884f63aab6b69cad5fb9b793d (diff) |
* console.c (parse_color): Check the character pointed by tail instead
of its address.
Diffstat (limited to 'console')
-rw-r--r-- | console/ChangeLog | 5 | ||||
-rw-r--r-- | console/console.c | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/console/ChangeLog b/console/ChangeLog index 7422ee61..45b0dc99 100644 --- a/console/ChangeLog +++ b/console/ChangeLog @@ -1,3 +1,8 @@ +2008-06-10 Samuel Thibault <samuel.thibault@ens-lyon.org> + + * console.c (parse_color): Check the character pointed by tail instead + of its address. + 2007-11-13 Thomas Schwinge <tschwinge@gnu.org> * console.c (netfs_attempt_utimes): Adapt to ``struct stat'' changes. diff --git a/console/console.c b/console/console.c index e4c6183d..991de2ae 100644 --- a/console/console.c +++ b/console/console.c @@ -1364,7 +1364,7 @@ parse_color (const char *name, int *number) errno = 0; nr = strtol (name, &tail, 0); - if (errno || &tail || nr < 0 || nr > CONS_COLOR_MAX) + if (errno || *tail || nr < 0 || nr > CONS_COLOR_MAX) return EINVAL; *number = nr; return 0; |