Changeset a2fadb4 in code for logger.c


Ignore:
Timestamp:
Mar 7, 2014, 3:21:30 PM (11 years ago)
Author:
Mike Belopuhov <mike@…>
Branches:
master
Children:
8871953
Parents:
270fd23
git-author:
Mike Belopuhov <mike@…> (03/07/14 15:17:23)
git-committer:
Mike Belopuhov <mike@…> (03/07/14 15:21:30)
Message:

Get rid of ICB_MSGSIZE+1, fix various off-by-ones and do some truncation
where necessary.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • logger.c

    r270fd23 ra2fadb4  
    197197                        return;
    198198                /* terminate the buffer */
    199                 m[MIN(nread - sizeof *e, ICB_MSGSIZE)] = '\0';
     199                m[MIN(nread - sizeof *e, ICB_MSGSIZE - 1)] = '\0';
    200200                /* find the appropriate log file */
    201201                for (i = 0; i < nlogfiles; i++)
Note: See TracChangeset for help on using the changeset viewer.