colourtran.c: Swap round arg names to colourtran_colournumbertoGCOL to match prototype. txtar.c: Avoid incorrect use of strncat buffer limit, and possible unterminated string after strncpy, by reexpressing using snprintf. txtedit.c: Avoid incorrect use of strncat buffer limit by reexpressing using snprintf. Avoid potential NULL pointer dereference by moving the filename copy inside the 'if' which confirms it's non-NULL. txtfind.c: Remove repeated check of repls being valid. Free repls on error. Free pat on error. xfersend.c: Fix potential out of bounds array access (of leaf) if the leafname length exceeds the space in the Wimp message. Found by cppcheck static analysis. txtopt.c/h: Sprinkle in some consts. event.c: Open menu at the Style Guide approved offset of 64. xfersend.c: Remove redundant check of xfersend__filename being NULL in xfersend__suggest_leaf() as all paths leading to it being called ensure the allocation exists (also, it would have strcpy'd garbage due to malloc not clearing the allocation). Removed unused header txtover.h. Version 5.98. Tagged as 'RISC_OSLib-5_98'
Showing with 44 additions and 72 deletions