diff options
author | Joshua Haberman <joshua@reverberate.org> | 2009-03-03 22:20:57 -0800 |
---|---|---|
committer | Joshua Haberman <joshua@reverberate.org> | 2009-03-03 22:20:57 -0800 |
commit | a714989094a67315d17642e142c62a2e5abebb7e (patch) | |
tree | 8606d8748479007961fb97688846402d1d88f0c1 /pbstream.h | |
parent | 9f56ff3b5bd4d019b8df546fdf59adecddc904bc (diff) |
Detect overflow (unlikely except for malicious input).
Diffstat (limited to 'pbstream.h')
-rw-r--r-- | pbstream.h | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -153,6 +153,9 @@ typedef enum pbstream_status { // Input was nested more than PBSTREAM_MAX_STACK deep. PBSTREAM_ERROR_STACK_OVERFLOW = -4, + // The input data caused the pb's offset (a size_t) to overflow. + PBSTREAM_ERROR_OVERFLOW = -5, + /** NONFATAL ERRORS: the input was invalid, but we can continue if desired. */ // A value was encountered that was not defined in the .proto file. The |