- Use direct character assignment for constant strings
- Remove unnecessary tracking array and cleanup code
- Simplify string concatenation logic
- Fix length calculation to match actual strncat behavior
- Code is cleaner and more maintainable
Co-authored-by: squassina <8495707+squassina@users.noreply.github.com>
- Add LAYOUT_ABBR_SIZE constant to avoid magic numbers
- Track allocated argv entries to properly free on error
- Simplify strncat bounds checking using strlen for accuracy
- Ensure all allocated memory is freed in error paths
Co-authored-by: squassina <8495707+squassina@users.noreply.github.com>
- Fix buffer size for strncpy to match actual buffer (32 bytes)
- Use strtoul instead of strtol for unsigned color values
- Improve strncat bounds checking with accurate length tracking
- Free wordexp results immediately after use instead of batching
- Add strdup for wordexp strings to avoid use-after-free
Co-authored-by: squassina <8495707+squassina@users.noreply.github.com>