FIXES revision 1.4 1 1.1 christos /****************************************************************
2 1.1 christos Copyright (C) Lucent Technologies 1997
3 1.1 christos All Rights Reserved
4 1.1 christos
5 1.1 christos Permission to use, copy, modify, and distribute this software and
6 1.1 christos its documentation for any purpose and without fee is hereby
7 1.1 christos granted, provided that the above copyright notice appear in all
8 1.1 christos copies and that both that the copyright notice and this
9 1.1 christos permission notice and warranty disclaimer appear in supporting
10 1.1 christos documentation, and that the name Lucent Technologies or any of
11 1.1 christos its entities not be used in advertising or publicity pertaining
12 1.1 christos to distribution of the software without specific, written prior
13 1.1 christos permission.
14 1.1 christos
15 1.1 christos LUCENT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
16 1.1 christos INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS.
17 1.1 christos IN NO EVENT SHALL LUCENT OR ANY OF ITS ENTITIES BE LIABLE FOR ANY
18 1.1 christos SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
19 1.1 christos WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
20 1.1 christos IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
21 1.1 christos ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
22 1.1 christos THIS SOFTWARE.
23 1.1 christos ****************************************************************/
24 1.1 christos
25 1.4 christos This file lists all bug fixes, changes, etc., made since the
26 1.4 christos second edition of the AWK book was published in September 2023.
27 1.1 christos
28 1.4 christos Jul 28, 2024
29 1.4 christos Fixed readcsvrec resize segfault when reading csv records longer
30 1.4 christos than 8k. Thanks to Ozan Yigit.
31 1.4 christos mktime() added to bsd-features branch. Thanks to Todd Miller.
32 1.4 christos
33 1.4 christos Jun 23, 2024
34 1.4 christos Fix signal for system-status test. Thanks to Tim van der Molen.
35 1.4 christos Rewrite if-else chain as switch. Thanks to Andrew Sukach.
36 1.4 christos
37 1.4 christos May 27, 2024
38 1.4 christos Spelling fixes and removal of unneeded prototypes and extern.
39 1.4 christos Thanks to Jonathan Gray.
40 1.4 christos
41 1.4 christos May 4, 2024
42 1.4 christos Fixed a use-after-free bug with ARGV for "delete ARGV".
43 1.4 christos Also ENVtab is no longer global. Thanks to Benjamin Sturz
44 1.4 christos for spotting the ARGV issue and Todd Miller for the fix.
45 1.4 christos
46 1.4 christos May 3, 2024:
47 1.4 christos Remove warnings when compiling with g++. Thanks to Arnold Robbins.
48 1.4 christos
49 1.4 christos Apr 22, 2024:
50 1.4 christos Fixed regex engine gototab reallocation issue that was
51 1.4 christos Introduced during the Nov 24 rewrite. Thanks to Arnold Robbins.
52 1.4 christos Fixed a scan bug in split in the case the separator is a single
53 1.4 christos character. Thanks to Oguz Ismail for spotting the issue.
54 1.4 christos
55 1.4 christos Mar 10, 2024:
56 1.4 christos Fixed use-after-free bug in fnematch due to adjbuf invalidating
57 1.4 christos the pointers to buf. Thanks to github user caffe3 for spotting
58 1.4 christos the issue and providing a fix, and to Miguel Pineiro Jr.
59 1.4 christos for the alternative fix.
60 1.4 christos MAX_UTF_BYTES in fnematch has been replaced with awk_mb_cur_max.
61 1.4 christos thanks to Miguel Pineiro Jr.
62 1.4 christos
63 1.4 christos Jan 22, 2024:
64 1.4 christos Restore the ability to compile with g++. Thanks to
65 1.3 christos Arnold Robbins.
66 1.3 christos
67 1.4 christos Dec 24, 2023:
68 1.4 christos Matchop dereference after free problem fix when the first
69 1.4 christos argument is a function call. Thanks to Oguz Ismail Uysal.
70 1.4 christos Fix inconsistent handling of --csv and FS set in the
71 1.4 christos command line. Thanks to Wilbert van der Poel.
72 1.4 christos Casting changes to int for is* functions.
73 1.4 christos
74 1.4 christos Nov 27, 2023:
75 1.4 christos Fix exit status of system on MacOS. Update to REGRESS.
76 1.4 christos Thanks to Arnold Robbins.
77 1.4 christos Fix inconsistent handling of -F and --csv, and loss of csv
78 1.4 christos mode when FS is set.
79 1.4 christos
80 1.4 christos Nov 24, 2023:
81 1.4 christos Fix issue #199: gototab improvements to dynamically resize the
82 1.4 christos table, qsort and bsearch to improve the lookup speed as the
83 1.4 christos table gets larger for multibyte input. Thanks to Arnold Robbins.
84 1.4 christos
85 1.4 christos Nov 23, 2023:
86 1.4 christos Fix Issue #169, related to escape sequences in strings.
87 1.4 christos Thanks to Github user rajeevvp.
88 1.4 christos Fix Issue #147, reported by Github user drawkula, and fixed
89 1.4 christos by Miguel Pineiro Jr.
90 1.4 christos
91 1.4 christos Nov 20, 2023:
92 1.4 christos Rewrite of fnematch to fix a number of issues, including
93 1.4 christos extraneous output, out-of-bounds access, number of bytes
94 1.4 christos to push back after a failed match etc.
95 1.4 christos Thanks to Miguel Pineiro Jr.
96 1.4 christos
97 1.4 christos Nov 15, 2023:
98 1.4 christos Man page edit, regression test fixes. Thanks to Arnold Robbins
99 1.4 christos Consolidation of sub and gsub into dosub, removing duplicate
100 1.4 christos code. Thanks to Miguel Pineiro Jr.
101 1.4 christos gcc replaced with cc everywhere.
102 1.4 christos
103 1.4 christos Oct 30, 2023:
104 1.4 christos Multiple fixes and a minor code cleanup.
105 1.4 christos Disabled utf-8 for non-multibyte locales, such as C or POSIX.
106 1.4 christos Fixed a bad char * cast that causes incorrect results on big-endian
107 1.4 christos systems. Also fixed an out-of-bounds read for empty CCL.
108 1.4 christos Fixed a buffer overflow in substr with utf-8 strings.
109 1.4 christos Many thanks to Todd C Miller.
110 1.4 christos
111 1.4 christos Sep 24, 2023:
112 1.4 christos fnematch and getrune have been overhauled to solve issues around
113 1.4 christos unicode FS and RS. Also fixed gsub null match issue with unicode.
114 1.4 christos Big thanks to Arnold Robbins.
115 1.4 christos
116 1.4 christos Sep 12, 2023:
117 1.4 christos Fixed a length error in u8_byte2char that set RSTART to
118 1.4 christos incorrect (cannot happen) value for EOL match(str, /$/).
119 1.4 christos
120 1.4 christos
121 1.4 christos -----------------------------------------------------------------
122 1.4 christos
123 1.4 christos [This entry is a summary, not a precise list of changes.]
124 1.4 christos
125 1.4 christos Added --csv option to enable processing of comma-separated
126 1.4 christos values inputs. When --csv is enabled, fields are separated
127 1.4 christos by commas, fields may be quoted with " double quotes, fields
128 1.4 christos may contain embedded newlines.
129 1.4 christos
130 1.4 christos If no explicit separator argument is provided, split() uses
131 1.4 christos the setting of --csv to determine how fields are split.
132 1.4 christos
133 1.4 christos Strings may now contain UTF-8 code points (not necessarily
134 1.4 christos characters). Functions that operate on characters, like
135 1.4 christos length, substr, index, match, etc., use UTF-8, so the length
136 1.4 christos of a string of 3 emojis is 3, not 12 as it would be if bytes
137 1.4 christos were counted.
138 1.4 christos
139 1.4 christos Regular expressions are processed as UTF-8.
140 1.4 christos
141 1.4 christos Unicode literals can be written as \u followed by one
142 1.4 christos to eight hexadecimal digits. These may appear in strings and
143 1.4 christos regular expressions.
144