Message ID | 1421943076-12240-2-git-send-email-ciprian.barbu@linaro.org |
---|---|
State | New |
Headers | show
Return-Path: <patchwork-forward+bncBC42RN5IWUGBBROCQSTAKGQES4FQPSQ@linaro.org> X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ee0-f71.google.com (mail-ee0-f71.google.com [74.125.83.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id E6A61240DB for <linaro@patches.linaro.org>; Thu, 22 Jan 2015 16:11:49 +0000 (UTC) Received: by mail-ee0-f71.google.com with SMTP id d49sf2180975eek.2 for <linaro@patches.linaro.org>; Thu, 22 Jan 2015 08:11:49 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:date:message-id:in-reply-to :references:subject:precedence:list-id:list-unsubscribe:list-archive :list-post:list-help:list-subscribe:mime-version:content-type :content-transfer-encoding:errors-to:sender:x-original-sender :x-original-authentication-results:mailing-list; bh=BSnnkX3/crCMFt1uvjJleEWul6KIkNYvfLaLcRZQecw=; b=X6IQ5jlPnEerbQ1ClhUxEeroYX2JMv6wUIyJLOASCQT7Fu3qlVI2jM3FDlg2gNe4tE 1t5t7++BO0ZPO6v/z7l0QYufinH82Z+S4vHBWMJNHyQrZzfv3aSSEOmP19tVuBzxSq6o pMebUvYoPn+Vv2vuYWYYBs3DyZuUeQVIAEhKar3E176y2iPtgjQ+lDDpIenG1UWNi+TO ZlwoRzE/amjd01zGwDrWXi3R84pRbzef7fwMMlUleEK4EyHkEVpVKWl4b7xVIFwFua9M u9LYMgphRKFXxzabB58f7KLuCGcD85pQiZbP7tirP2jRsgrmhsFYiCpS2kS+4+sPFxn8 Js2g== X-Gm-Message-State: ALoCoQk/3QdMOZ/QoKH5lC2PZdKRZugolw8f2ryj/089vzv+L8RU/aI6EUeBMdfndPf3KqGEZZ0O X-Received: by 10.112.168.163 with SMTP id zx3mr6510lbb.24.1421943109168; Thu, 22 Jan 2015 08:11:49 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.170.193 with SMTP id ao1ls65827lac.20.gmail; Thu, 22 Jan 2015 08:11:49 -0800 (PST) X-Received: by 10.112.160.33 with SMTP id xh1mr2634716lbb.60.1421943109021; Thu, 22 Jan 2015 08:11:49 -0800 (PST) Received: from mail-lb0-f175.google.com (mail-lb0-f175.google.com. [209.85.217.175]) by mx.google.com with ESMTPS id fb6si21035704lbc.117.2015.01.22.08.11.48 for <patchwork-forward@linaro.org> (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 22 Jan 2015 08:11:49 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) client-ip=209.85.217.175; Received: by mail-lb0-f175.google.com with SMTP id 10so1194443lbg.6 for <patchwork-forward@linaro.org>; Thu, 22 Jan 2015 08:11:48 -0800 (PST) X-Received: by 10.152.7.229 with SMTP id m5mr2607046laa.80.1421943108916; Thu, 22 Jan 2015 08:11:48 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp312561lbb; Thu, 22 Jan 2015 08:11:48 -0800 (PST) X-Received: by 10.224.36.14 with SMTP id r14mr4002740qad.39.1421943107618; Thu, 22 Jan 2015 08:11:47 -0800 (PST) Received: from ip-10-35-177-41.ec2.internal (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTPS id t6si9436940qat.37.2015.01.22.08.11.45 (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 22 Jan 2015 08:11:47 -0800 (PST) Received-SPF: none (google.com: lng-odp-bounces@lists.linaro.org does not designate permitted sender hosts) client-ip=54.225.227.206; Received: from localhost ([127.0.0.1] helo=ip-10-35-177-41.ec2.internal) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from <lng-odp-bounces@lists.linaro.org>) id 1YEKMB-0000B9-JQ; Thu, 22 Jan 2015 16:11:43 +0000 Received: from mail-lb0-f179.google.com ([209.85.217.179]) by ip-10-35-177-41.ec2.internal with esmtp (Exim 4.76) (envelope-from <ciprian.barbu@linaro.org>) id 1YEKM2-0000A5-7W for lng-odp@lists.linaro.org; Thu, 22 Jan 2015 16:11:34 +0000 Received: by mail-lb0-f179.google.com with SMTP id 10so1182334lbg.10 for <lng-odp@lists.linaro.org>; Thu, 22 Jan 2015 08:11:28 -0800 (PST) X-Received: by 10.112.135.99 with SMTP id pr3mr2535170lbb.61.1421943088636; Thu, 22 Jan 2015 08:11:28 -0800 (PST) Received: from cipriantemp.enea.se (sestofw01.enea.se. [192.36.1.252]) by mx.google.com with ESMTPSA id o1sm6428902laj.29.2015.01.22.08.11.27 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 22 Jan 2015 08:11:27 -0800 (PST) From: Ciprian Barbu <ciprian.barbu@linaro.org> To: zoltan.kiss@linaro.org, lng-odp@lists.linaro.org Date: Thu, 22 Jan 2015 18:11:12 +0200 Message-Id: <1421943076-12240-2-git-send-email-ciprian.barbu@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1421943076-12240-1-git-send-email-ciprian.barbu@linaro.org> References: <1421943076-12240-1-git-send-email-ciprian.barbu@linaro.org> X-Topics: patch Subject: [lng-odp] [PATCH odp-ovs 1/3] ofpbuf: init the buffer source before any other operations X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: <patchwork-forward.linaro.org> List-Unsubscribe: <mailto:googlegroups-manage+836684582541+unsubscribe@googlegroups.com>, <http://groups.google.com/a/linaro.org/group/patchwork-forward/subscribe> List-Archive: <http://groups.google.com/a/linaro.org/group/patchwork-forward/> List-Post: <http://groups.google.com/a/linaro.org/group/patchwork-forward/post>, <mailto:patchwork-forward@linaro.org> List-Help: <http://support.google.com/a/linaro.org/bin/topic.py?topic=25838>, <mailto:patchwork-forward+help@linaro.org> List-Subscribe: <http://lists.linaro.org/mailman/listinfo/lng-odp>, <mailto:lng-odp-request@lists.linaro.org?subject=subscribe> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: lng-odp-bounces@lists.linaro.org Sender: lng-odp-bounces@lists.linaro.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ciprian.barbu@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 |
diff --git a/lib/ofpbuf.c b/lib/ofpbuf.c index 764a799..6f27b47 100644 --- a/lib/ofpbuf.c +++ b/lib/ofpbuf.c @@ -38,11 +38,11 @@ static void ofpbuf_use__(struct ofpbuf *b, void *base, size_t allocated, enum ofpbuf_source source) { + ofpbuf_init__(b, allocated, source); + ofpbuf_set_base(b, base); ofpbuf_set_data(b, base); ofpbuf_set_size(b, 0); - - ofpbuf_init__(b, allocated, source); } /* Initializes 'b' as an empty ofpbuf that contains the 'allocated' bytes of
Signed-off-by: Ciprian Barbu <ciprian.barbu@linaro.org> --- The source was not initialized before calling ofpbuf_init__, which is needed by the ODP netdev implementation. lib/ofpbuf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)