X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=ofproto%2Fpktbuf.c;h=c103c7ffb0715f8478d4480de914406ffc0de472;hb=3c5f6de3856fa47aa184ca389dcb8d4fcc13d29a;hp=495a1ee3772d695088f5fe49f600a52ca2a6f089;hpb=49bdc010dfc9f396eec608148ca0f4ea71a0c4dd;p=openvswitch diff --git a/ofproto/pktbuf.c b/ofproto/pktbuf.c index 495a1ee3..c103c7ff 100644 --- a/ofproto/pktbuf.c +++ b/ofproto/pktbuf.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2008, 2009 Nicira Networks. + * Copyright (c) 2008, 2009, 2010 Nicira Networks. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -151,9 +151,9 @@ pktbuf_get_null(void) * datapath port number on which the packet was received in '*in_port'. The * caller becomes responsible for freeing the buffer. However, if 'id' * identifies a "null" packet buffer (created with pktbuf_get_null()), stores - * NULL in '*bufferp' and -1 in '*in_port'. + * NULL in '*bufferp' and UINT16_max in '*in_port'. * - * On failure, stores NULL in in '*bufferp' and -1 in '*in_port'. */ + * On failure, stores NULL in in '*bufferp' and UINT16_MAX in '*in_port'. */ int pktbuf_retrieve(struct pktbuf *pb, uint32_t id, struct ofpbuf **bufferp, uint16_t *in_port) @@ -194,7 +194,7 @@ pktbuf_retrieve(struct pktbuf *pb, uint32_t id, struct ofpbuf **bufferp, error = 0; } *bufferp = NULL; - *in_port = -1; + *in_port = UINT16_MAX; return error; }