From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2103) id D506D385734E; Tue, 21 Jun 2022 18:30:20 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org D506D385734E Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable From: Nick Alcock To: bfd-cvs@sourceware.org, gdb-cvs@sourceware.org Subject: [binutils-gdb] libctf: avoid mingw warning X-Act-Checkin: binutils-gdb X-Git-Author: Nick Alcock X-Git-Refname: refs/heads/master X-Git-Oldrev: 6bd2318f32842a27b03677b670421f93c14f9302 X-Git-Newrev: 3ec2b3c05887bd00a6d4a4e94e004c6d9d2f70eb Message-Id: <20220621183020.D506D385734E@sourceware.org> Date: Tue, 21 Jun 2022 18:30:20 +0000 (GMT) X-BeenThere: gdb-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gdb-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Jun 2022 18:30:20 -0000 https://sourceware.org/git/gitweb.cgi?p=3Dbinutils-gdb.git;h=3D3ec2b3c05887= bd00a6d4a4e94e004c6d9d2f70eb commit 3ec2b3c05887bd00a6d4a4e94e004c6d9d2f70eb Author: Nick Alcock Date: Fri Jun 10 19:06:59 2022 +0100 libctf: avoid mingw warning =20 A missing paren led to an intended cast to avoid dependence on the size of size_t in one argument of ctf_err_warn applying to the wrong type by mistake. =20 libctf/ChangeLog: =20 * ctf-serialize.c (ctf_write_mem): Fix cast. Diff: --- libctf/ctf-serialize.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libctf/ctf-serialize.c b/libctf/ctf-serialize.c index c6b8b495568..ecbc61783f2 100644 --- a/libctf/ctf-serialize.c +++ b/libctf/ctf-serialize.c @@ -1319,7 +1319,7 @@ ctf_write_mem (ctf_dict_t *fp, size_t *size, size_t t= hreshold) { ctf_set_errno (fp, ENOMEM); ctf_err_warn (fp, 0, 0, _("ctf_write_mem: cannot allocate %li bytes"), - (unsigned long) fp->ctf_size + sizeof (struct ctf_header)); + (unsigned long) (fp->ctf_size + sizeof (struct ctf_header))); return NULL; } ctf_flip_header (hp);