* grub-core/fs/bfs.c (bfs_strcmp) [MODE_AFS]: Use signed comparison.
This commit is contained in:
parent
1796965f6c
commit
0a308f64e9
2 changed files with 12 additions and 1 deletions
|
@ -1,3 +1,7 @@
|
|||
2012-05-04 Vladimir Serbinenko <phcoder@gmail.com>
|
||||
|
||||
* grub-core/fs/bfs.c (bfs_strcmp) [MODE_AFS]: Use signed comparison.
|
||||
|
||||
2012-05-04 Samuel Thibault <samuel.thibault@ens-lyon.org>
|
||||
|
||||
* util/getroot.c (find_hurd_root_device): Try to make error message
|
||||
|
|
|
@ -519,10 +519,17 @@ bfs_strcmp (const char *a, const char *b, grub_size_t alen)
|
|||
alen--;
|
||||
}
|
||||
|
||||
#ifdef MODE_AFS
|
||||
if (!alen)
|
||||
return - (int) (grub_int8_t) *b;
|
||||
|
||||
return (int) (grub_int8_t) *a - (int) (grub_int8_t) *b;
|
||||
#else
|
||||
if (!alen)
|
||||
return - (int) (grub_uint8_t) *b;
|
||||
|
||||
return (int) (grub_uint8_t) *a - (int) (grub_uint8_t) *b;
|
||||
#endif
|
||||
}
|
||||
|
||||
static grub_err_t
|
||||
|
|
Loading…
Reference in a new issue