summaryrefslogtreecommitdiffstats
path: root/src/hardcopy.c
AgeCommit message (Collapse)Author
2024-01-04patch 9.1.0006: is*() and to*() function may be unsafev9.1.0006Keith Thompson
Problem: is*() and to*() function may be unsafe Solution: Add SAFE_* macros and start using those instead (Keith Thompson) Use SAFE_() macros for is*() and to*() functions The standard is*() and to*() functions declared in <ctype.h> have undefined behavior for negative arguments other than EOF. If plain char is signed, passing an unchecked value from argv for from user input to one of these functions has undefined behavior. Solution: Add SAFE_*() macros that cast the argument to unsigned char. Most implementations behave sanely for negative arguments, and most character values in practice are non-negative, but it's still best to avoid undefined behavior. The change from #13347 has been omitted, as this has already been separately fixed in commit ac709e2fc0db6d31abb7da96f743c40956b60c3a (v9.0.2054) fixes: #13332 closes: #13347 Signed-off-by: Keith Thompson <Keith.S.Thompson@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
2023-03-07patch 9.0.1391: "clear" macros are not always usedv9.0.1391Yegappan Lakshmanan
Problem: "clear" macros are not always used. Solution: Use ALLOC_ONE, VIM_CLEAR, CLEAR_POINTER and CLEAR_FIELD in more places. (Yegappan Lakshmanan, closes #12104)
2023-02-20patch 9.0.1330: handling new value of an option has a long "else if" chainv9.0.1330Yegappan Lakshmanan
Problem: Handling new value of an option has a long "else if" chain. Solution: Use a function pointer. (Yegappan Lakshmanan, closes #12015)
2023-01-09patch 9.0.1166: code is indented more than necessaryv9.0.1166Yegappan Lakshmanan
Problem: Code is indented more than necessary. Solution: Use an early return where it makes sense. (Yegappan Lakshmanan, closes #11792)
2022-11-07patch 9.0.0844: handling 'statusline' errors is spread outv9.0.0844Luuk van Baal
Problem: Handling 'statusline' errors is spread out. Solution: Pass the option name to the lower levels so the option can be reset there when an error is encountered. (Luuk van Baal, closes #11467)
2022-06-29patch 9.0.0007: no support for double, dotted and dashed underlinesv9.0.0007Bram Moolenaar
Problem: No support for double, dotted and dashed underlines. Solution: Add the termcap entries and highlight modes. (closes #9553)
2022-01-31patch 8.2.4273: the EBCDIC support is outdatedv8.2.4273Bram Moolenaar
Problem: The EBCDIC support is outdated. Solution: Remove the EBCDIC support.
2022-01-29patch 8.2.4255: theoretical computation overflowv8.2.4255=?UTF-8?q?Dundar=20G=C3=B6c?=
Problem: Theoretical computation overflow. Solution: Perform multiplication in a wider type. (closes #9657)
2022-01-08patch 8.2.4043: using int for second argument of ga_init2()v8.2.4043Bram Moolenaar
Problem: Using int for second argument of ga_init2(). Solution: Remove unnessary type cast (int) when using sizeof().
2022-01-04patch 8.2.4005: error messages are spread outv8.2.4005Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-04patch 8.2.4003: error messages are spread outv8.2.4003Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-02patch 8.2.3987: error messages are spread outv8.2.3987Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-02patch 8.2.3986: error messages are spread outv8.2.3986Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-02patch 8.2.3985: error messages are spread outv8.2.3985Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-02patch 8.2.3983: error messages are spread outv8.2.3983Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more error messages to errors.h.
2022-01-01patch 8.2.3967: error messages are spread outv8.2.3967Bram Moolenaar
Problem: Error messages are spread out. Solution: Move more errors to errors.h.
2021-10-02patch 8.2.3460: some type casts are not neededv8.2.3460=?UTF-8?q?Dundar=20G=C3=B6c?=
Problem: Some type casts are not needed. Solution: Remove unnecessary type casts. (closes #8934)
2021-06-02patch 8.2.2922: computing array length is done in various waysv8.2.2922K.Takata
Problem: Computing array length is done in various ways. Solution: Use ARRAY_LENGTH everywhere. (Ken Takata, closes #8305)
2020-04-12patch 8.2.0559: clearing a struct is verbosev8.2.0559Bram Moolenaar
Problem: Clearing a struct is verbose. Solution: Define and use CLEAR_FIELD() and CLEAR_POINTER().
2019-12-04patch 8.1.2387: using old C style commentsv8.1.2387Bram Moolenaar
Problem: Using old C style comments. Solution: Use // comments where appropriate.
2019-05-28patch 8.1.1414: alloc() returning "char_u *" causes a lot of type castsv8.1.1414Bram Moolenaar
Problem: Alloc() returning "char_u *" causes a lot of type casts. Solution: Have it return "void *". (Mike Williams) Define ALLOC_ONE() to check the simple allocations.
2019-05-10patch 8.1.1313: warnings for using localtime() and ctime()v8.1.1313Bram Moolenaar
Problem: Warnings for using localtime() and ctime(). Solution: Use localtime_r() if available. Avoid using ctime().
2019-01-24patch 8.1.0806: too many #ifdefsv8.1.0806Bram Moolenaar
Problem: Too many #ifdefs. Solution: Graduate FEAT_MBYTE, part 2.
2019-01-19patch 8.1.0779: argument for message functions is inconsistentv8.1.0779Bram Moolenaar
Problem: Argument for message functions is inconsistent. Solution: Make first argument to msg() "char *".
2019-01-13patch 8.1.0743: giving error messages is not flexiblev8.1.0743Bram Moolenaar
Problem: Giving error messages is not flexible. Solution: Add semsg(). Change argument from "char_u *" to "char *", also for msg() and get rid of most MSG macros. (Ozaki Kiichi, closes #3302) Also make emsg() accept a "char *" argument. Get rid of an enormous number of type casts.
2018-09-30patch 8.1.0443: unnecessary static function prototypesv8.1.0443Bram Moolenaar
Problem: Unnecessary static function prototypes. Solution: Remove unnecessary prototypes.
2018-06-23patch 8.1.0105: all tab stops are the samev8.1.0105Bram Moolenaar
Problem: All tab stops are the same. Solution: Add the variable tabstop feature. (Christian Brabandt, closes #2711)
2018-06-16patch 8.1.0056: crash when using :hardcopy with illegal bytev8.1.0056Bram Moolenaar
Problem: Crash when using :hardcopy with illegal byte. Solution: Check for string_convert() returning NULL. (Dominique Pelle)
2018-02-11patch 8.0.1503: access memory beyond end of stringv8.0.1503Bram Moolenaar
Problem: Access memory beyond end of string. (Coverity) Solution: Keep allocated memory in separate pointer. Avoid outputting the NUL character.
2018-02-10patch 8.0.1496: clearing a pointer takes two linesv8.0.1496Bram Moolenaar
Problem: Clearing a pointer takes two lines. Solution: Add VIM_CLEAR() and replace vim_clear(). (Hirohito Higashi, closes #2629)
2017-03-16patch 8.0.0466: still macros that should be all-capsv8.0.0466Bram Moolenaar
Problem: There are still a few macros that should be all-caps. Solution: Make a few more macros all-caps.
2016-08-29patch 7.4.2293v7.4.2293Bram Moolenaar
Problem: Modelines in source code are inconsistant. Solution: Use the same line in most files. Add 'noet'. (Naruhiko Nishino)
2016-04-29patch 7.4.1799v7.4.1799Bram Moolenaar
Problem: 'guicolors' is a confusing option name. Solution: Use 'termguicolors' instead. (Hirohito Higashi)
2016-04-21patch 7.4.1770v7.4.1770Bram Moolenaar
Problem: Cannot use true color in the terminal. Solution: Add the 'guicolors' option. (Nikolai Pavlov)
2016-04-03patch 7.4.1702v7.4.1702Bram Moolenaar
Problem: Using freed memory when parsing 'printoptions' fails. Solution: Save the old options and restore them in case of an error. (Dominique)
2016-03-12patch 7.4.1552v7.4.1552Bram Moolenaar
Problem: ":colorscheme" does not use 'packpath'. Solution: Also use in "start" and "opt" directories in 'packpath'.
2016-01-30patch 7.4.1208v7.4.1208Bram Moolenaar
Problem: Using old style function declarations. Solution: Change to new style function declarations. (script by Hirohito Higashi)
2016-01-29patch 7.4.1198v7.4.1198Bram Moolenaar
Problem: Still using __ARGS. Solution: Remove __ARGS in several files. (script by Hirohito Higashi) Also remove use of HAVE_STDARG_H.
2015-04-15patch 7.4.701v7.4.701Bram Moolenaar
Problem: Compiler warning for using uninitialized variable. (Yasuhiro Matsumoto) Solution: Initialize it.
2015-04-13patch 7.4.695v7.4.695Bram Moolenaar
Problem: Out-of-bounds read, dectected by Coverity. Solution: Remember the value of cmap for the first matching encoding. Reset cmap to that value if first matching encoding is going to be used. (Eliseo Martínez)
2015-03-31updated for version 7.4.684v7.4.684Bram Moolenaar
Problem: When starting several Vim instances in diff mode, the temp files used may not be unique. (Issue 353) Solution: Add an argument to vim_tempname() to keep the file.
2014-11-27updated for version 7.4.533v7.4.533Bram Moolenaar
Problem: ":hardcopy" leaks memory in case of errors. Solution: Free memory in all code paths. (Christian Brabandt)
2013-05-06updated for version 7.3.925v7.3.925Bram Moolenaar
Problem: Typos in source files. Solution: Fix the typos. (Ken Takata)
2011-04-11updated for version 7.3.161v7.3.161Bram Moolenaar
Problem: Items on the stack may be too big. Solution: Make items static or allocate them.
2011-04-11updated for version 7.3.160v7.3.160Bram Moolenaar
Problem: Unsafe string copying. Solution: Use vim_strncpy() instead of strcpy(). Use vim_strcat() instead of strcat().
2010-07-31Fixes for coverity warnings.Bram Moolenaar
2010-06-05Add the conceal patch from Vince Negri.Bram Moolenaar
2010-05-24Fix uninit memory read in undo code. Fix uint32_t in proto file.Bram Moolenaar
A few minor changes.
2009-05-16updated for version 7.2-177v7.2.177Bram Moolenaar
2008-01-12updated for version 7.1-219v7.1.219Bram Moolenaar