X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;ds=sidebyside;f=lib%2Fofpbuf.c;h=d578ab56a229b81537ce25b3bf0de369fb89c367;hb=ac60863f78e412004c5b69f5a64a49bc6f0bc46d;hp=c960a7e86f99f8fcee0c5a981a9d972c8fda8bf2;hpb=125638ebd7fa77fb98710ae0eb91b25172f9f725;p=sliver-openvswitch.git diff --git a/lib/ofpbuf.c b/lib/ofpbuf.c index c960a7e86..d578ab56a 100644 --- a/lib/ofpbuf.c +++ b/lib/ofpbuf.c @@ -67,7 +67,7 @@ ofpbuf_use_stack(struct ofpbuf *b, void *base, size_t allocated) /* Initializes 'b' as an empty ofpbuf that contains the 'allocated' bytes of * memory starting at 'base'. 'base' should point to a buffer on the stack. * (Nothing actually relies on 'base' being allocated on the stack. It could - * be static or malloc()'d memory. But stack space is the most common usen + * be static or malloc()'d memory. But stack space is the most common use * case.) * * 'base' should be appropriately aligned. Using an array of uint32_t or @@ -407,7 +407,7 @@ ofpbuf_put_hex(struct ofpbuf *b, const char *s, size_t *n) uint8_t byte; bool ok; - s += strspn(s, " "); + s += strspn(s, " \t\r\n"); byte = hexits_value(s, 2, &ok); if (!ok) { if (n) {