diff options
author | Patrick McDermott <patrick.mcdermott@libiquity.com> | 2019-07-18 19:43:06 (EDT) |
---|---|---|
committer | Patrick McDermott <patrick.mcdermott@libiquity.com> | 2019-07-18 19:43:06 (EDT) |
commit | 373c9218245263fe986f4b93ef62cfa9af6c644b (patch) | |
tree | 4db01ec2d312879e9810060c50a816a992343c44 /src/sgr.c | |
parent | 8225911a9c19f5c738397488ccebf510490536f3 (diff) |
assert() function arguments
Diffstat (limited to 'src/sgr.c')
-rw-r--r-- | src/sgr.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -21,6 +21,7 @@ #include "sgr.h" +#include <assert.h> #include <stdlib.h> #include <string.h> @@ -57,6 +58,10 @@ sgr(unsigned char *param, png_colorp fg, png_colorp bg) unsigned char *p; int i; + assert(param); + assert(fg); + assert(bg); + end = 0; for (p = param; param; ++param) { if (*param == ';' || *param == ':' || *param == '\0') { |