Skip to content

Commit

Permalink
replaced a malloc()+bzero() with calloc()
Browse files Browse the repository at this point in the history
  • Loading branch information
sezero committed Jun 16, 2016
1 parent bd211db commit 8353acd
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/wm_error.c
Expand Up @@ -77,8 +77,7 @@ void _WM_GLOBAL_ERROR(const char * func, const char * file, unsigned int lne, in

if (_WM_Global_ErrorS != NULL) free(_WM_Global_ErrorS);

errorstring = malloc(MAX_ERROR_LEN+1);
bzero(errorstring, MAX_ERROR_LEN+1);
errorstring = calloc(1, MAX_ERROR_LEN+1);

if (error == 0) {
if (wmfor == NULL) {
Expand Down

0 comments on commit 8353acd

Please sign in to comment.