[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: * install-info/install-info.c (split_entry): Rewr
From: |
Gavin D. Smith |
Subject: |
branch master updated: * install-info/install-info.c (split_entry): Rewrite in slightly more obscure way to silence obnoxious gcc warning about use of strncat. |
Date: |
Mon, 09 Jan 2023 13:09:13 -0500 |
This is an automated email from the git hooks/post-receive script.
gavin pushed a commit to branch master
in repository texinfo.
The following commit(s) were added to refs/heads/master by this push:
new 78c6540931 * install-info/install-info.c (split_entry): Rewrite in
slightly more obscure way to silence obnoxious gcc warning about use of strncat.
78c6540931 is described below
commit 78c6540931b9da28518478dc6a816f4e2e74d497
Author: Gavin Smith <gavinsmith0123@gmail.com>
AuthorDate: Mon Jan 9 18:08:51 2023 +0000
* install-info/install-info.c (split_entry):
Rewrite in slightly more obscure way to silence obnoxious gcc
warning about use of strncat.
---
ChangeLog | 6 ++++++
install-info/install-info.c | 7 +++----
2 files changed, 9 insertions(+), 4 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index ede88825d5..ce06ea6468 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2023-01-09 Gavin Smith <gavinsmith0123@gmail.com>
+
+ * install-info/install-info.c (split_entry):
+ Rewrite in slightly more obscure way to silence obnoxious gcc
+ warning about use of strncat.
+
2023-01-09 Patrice Dumas <pertusus@free.fr>
* tp/t/input_files/delcomment_followed_by_cpp_line.texi: add more
diff --git a/install-info/install-info.c b/install-info/install-info.c
index b9f7dc8e1d..dcc36def2e 100644
--- a/install-info/install-info.c
+++ b/install-info/install-info.c
@@ -1,6 +1,6 @@
/* install-info -- merge Info directory entries from an Info file.
- Copyright 1996-2022 Free Software Foundation, Inc.
+ Copyright 1996-2023 Free Software Foundation, Inc.
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -1626,9 +1626,8 @@ split_entry (const char *entry, char **name, size_t
*name_len,
else
{
/* Just show the rest when there's no newline. */
- size_t length = strlen (ptr);
- strncat (*description, ptr, length);
- ptr += length;
+ strcat (*description, ptr);
+ ptr += strlen (ptr);
}
}
/* Descriptions end in a new line. */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: * install-info/install-info.c (split_entry): Rewrite in slightly more obscure way to silence obnoxious gcc warning about use of strncat.,
Gavin D. Smith <=