Skip to content

Commit

Permalink
[CWEB] Compile with G++-14 (locally).
Browse files Browse the repository at this point in the history
Avoid a "stringop truncation" warning with 'strncpy()'.

git-svn-id: svn://tug.org/texlive/trunk/Build/source@71824 c570f23f-e606-0410-a88d-b1316a301751
  • Loading branch information
Andreas Scherer committed Jul 17, 2024
1 parent 2b3e11a commit c3bce28
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
4 changes: 4 additions & 0 deletions texk/web2c/cwebdir/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2024-07-17 Andreas Scherer <https://ascherer.github.io>

* twinx.ch: Compile CWEB with G++-14.

2024-07-15 Andreas Scherer <https://ascherer.github.io>

* texinputs/pdfwebtocfront.tex: Release file resource early.
Expand Down
4 changes: 3 additions & 1 deletion texk/web2c/cwebdir/twinx.ch
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,12 @@ int main(
if((f=fopen(*++argv,"r"))==NULL)
@z

@x l.28
@x l.27
strncpy(*argv+strlen(*argv)-3,"idx",3);
f=fopen(*argv,"r");
if (!f)
@y
memcpy(*argv+strlen(*argv)-3,"idx",3);
if((f=fopen(*argv,"r"))==NULL)
@z

Expand Down

0 comments on commit c3bce28

Please sign in to comment.