From c88790775dc9db165bb15010da4efb3cf7458816 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Tue, 29 Jul 1997 15:06:48 +0000 Subject: [PATCH] * resbin.c (bin_to_res_string): Correct adjustment of data and length. From Ton van Overbeek . --- binutils/ChangeLog | 5 +++++ binutils/resbin.c | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/binutils/ChangeLog b/binutils/ChangeLog index 7cb371350a8..579ce278774 100644 --- a/binutils/ChangeLog +++ b/binutils/ChangeLog @@ -1,3 +1,8 @@ +Tue Jul 29 11:06:03 1997 Ian Lance Taylor + + * resbin.c (bin_to_res_string): Correct adjustment of data and + length. From Ton van Overbeek . + Tue Jul 22 18:01:23 1997 Ian Lance Taylor * nlmconv.c (link_inputs): Call libiberty pexecute function. diff --git a/binutils/resbin.c b/binutils/resbin.c index 47d102c4b90..24432d27eae 100644 --- a/binutils/resbin.c +++ b/binutils/resbin.c @@ -667,8 +667,8 @@ bin_to_res_string (data, length, big_endian) s[j] = get_16 (big_endian, data + 2 + j * 2); } - data += 2 + slen; - length -= 2 + slen; + data += 2 + 2 * slen; + length -= 2 + 2 * slen; } r = (struct res_resource *) res_alloc (sizeof *r); -- 2.30.2