strongswan.org
Wiki/Project Management
Downloads
Gitweb
projects
/
strongswan.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
represent 0 as a single byte
[strongswan.git]
/
src
/
libstrongswan
/
chunk.h
diff --git
a/src/libstrongswan/chunk.h
b/src/libstrongswan/chunk.h
index
4ff686f
..
3de02ee
100644
(file)
--- a/
src/libstrongswan/chunk.h
+++ b/
src/libstrongswan/chunk.h
@@
-239,12
+239,8
@@
static inline chunk_t chunk_skip(chunk_t chunk, size_t bytes)
*/
static inline chunk_t chunk_skip_zero(chunk_t chunk)
{
- if (chunk.len && *chunk.ptr == 0x00)
+ if (chunk.len
> 1
&& *chunk.ptr == 0x00)
{
- if (chunk.len == 1)
- {
- return chunk_empty;
- }
chunk.ptr++;
chunk.len--;
}