From: Bruno Haible Date: Sun, 28 Jul 2024 07:41:17 +0000 (+0200) Subject: Refactor. X-Git-Tag: v0.23~218 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06d909c45b416aae1c15d9f6f2941092209d9888;p=thirdparty%2Fgettext.git Refactor. * gettext-tools/src/message.h (message_comment_filepos): Change parameter names. * gettext-tools/src/message.c (message_comment_filepos): Likewise. --- diff --git a/gettext-tools/src/message.c b/gettext-tools/src/message.c index b852d0df8..8d6b88de0 100644 --- a/gettext-tools/src/message.c +++ b/gettext-tools/src/message.c @@ -1,5 +1,5 @@ /* GNU gettext - internationalization aids - Copyright (C) 1995-1998, 2000-2010, 2012-2013, 2015-2016, 2019-2020, 2023 Free Software Foundation, Inc. + Copyright (C) 1995-2024 Free Software Foundation, Inc. This file was written by Peter Miller @@ -204,7 +204,8 @@ message_comment_dot_append (message_ty *mp, const char *s) void -message_comment_filepos (message_ty *mp, const char *name, size_t line) +message_comment_filepos (message_ty *mp, + const char *file_name, size_t line_number) { size_t j; size_t nbytes; @@ -214,7 +215,8 @@ message_comment_filepos (message_ty *mp, const char *name, size_t line) for (j = 0; j < mp->filepos_count; j++) { pp = &mp->filepos[j]; - if (strcmp (pp->file_name, name) == 0 && pp->line_number == line) + if (strcmp (pp->file_name, file_name) == 0 + && pp->line_number == line_number) return; } @@ -224,8 +226,8 @@ message_comment_filepos (message_ty *mp, const char *name, size_t line) /* Insert the position at the end. Don't sort the file positions here. */ pp = &mp->filepos[mp->filepos_count++]; - pp->file_name = xstrdup (name); - pp->line_number = line; + pp->file_name = xstrdup (file_name); + pp->line_number = line_number; } diff --git a/gettext-tools/src/message.h b/gettext-tools/src/message.h index 4fa65989e..377272f52 100644 --- a/gettext-tools/src/message.h +++ b/gettext-tools/src/message.h @@ -1,5 +1,5 @@ /* GNU gettext - internationalization aids - Copyright (C) 1995-1998, 2000-2010, 2012-2013, 2015-2016, 2019-2020, 2023 Free Software Foundation, Inc. + Copyright (C) 1995-2024 Free Software Foundation, Inc. This file was written by Peter Miller @@ -241,7 +241,8 @@ extern void extern void message_comment_dot_append (message_ty *mp, const char *comment); extern void - message_comment_filepos (message_ty *mp, const char *name, size_t line); + message_comment_filepos (message_ty *mp, + const char *file_name, size_t line_number); extern message_ty * message_copy (message_ty *mp);