diff options
author | Nick Clifton <nickc@redhat.com> | 2002-04-09 17:06:14 +0000 |
---|---|---|
committer | Nick Clifton <nickc@redhat.com> | 2002-04-09 17:06:14 +0000 |
commit | b24eb5ac22f573f4f45547872cdadcf7f7c9d682 (patch) | |
tree | a72d2400770148709b242ee9fc21613167bf9447 /binutils/resrc.c | |
parent | f7d63484de877e1d0efe47ed768eb893332e5c5d (diff) | |
download | binutils-b24eb5ac22f573f4f45547872cdadcf7f7c9d682.zip binutils-b24eb5ac22f573f4f45547872cdadcf7f7c9d682.tar.gz binutils-b24eb5ac22f573f4f45547872cdadcf7f7c9d682.tar.bz2 |
Fix overlooked sublang shift bug.
Add testcase.
Diffstat (limited to 'binutils/resrc.c')
-rw-r--r-- | binutils/resrc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/binutils/resrc.c b/binutils/resrc.c index a9b3ba8..773e08a 100644 --- a/binutils/resrc.c +++ b/binutils/resrc.c @@ -1592,7 +1592,8 @@ write_rc_directory (e, rd, type, name, language, level) && (re->id.u.id & 0xffff) == re->id.u.id) { fprintf (e, "LANGUAGE %lu, %lu\n", - re->id.u.id & 0xff, (re->id.u.id >> 8) & 0xff); + re->id.u.id & ((1 << SUBLANG_SHIFT) - 1), + (re->id.u.id >> SUBLANG_SHIFT) & 0xff); *language = re->id.u.id; } break; |