From owner-svn-src-head@freebsd.org Tue Aug 14 19:58:35 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id A8BCD1058C5B; Tue, 14 Aug 2018 19:58:35 +0000 (UTC) (envelope-from garga.bsd@gmail.com) Received: from mail-qt0-x230.google.com (mail-qt0-x230.google.com [IPv6:2607:f8b0:400d:c0d::230]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3AA05852B9; Tue, 14 Aug 2018 19:58:35 +0000 (UTC) (envelope-from garga.bsd@gmail.com) Received: by mail-qt0-x230.google.com with SMTP id f18-v6so22464035qtp.10; Tue, 14 Aug 2018 12:58:35 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=subject:to:references:from:openpgp:autocrypt:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=u0vp2kIEIpsHJ47ukBzO049cj5gTPTYN2WNmr7IsmoE=; b=jilkeJhISiU0jMfbp2ase68/FL0FsOn482hViUGOgevKiXH6bHhAZbRVcq5eLwj7wb LtGtQO3KclMvkMCuZbGQ8Ydma4sApefW+K0iFgbWgDbN4ZZU+/4umOfEj7a1lECaGpkx HXazip3nZyZ6l4ieQNEb7HoEcSSMPQqnmhLA6efzP06iQJ4pHv2qO89FW+uQ9fPyR1Rt 3qUGJK1wDNJ5iqVUq6lHBU34e7fJ+9+l6GTq3KyMTcj0MOplVHSdqdJH7vMnsropDGQB iFqX/oCOCHGWPleKqgPlHF2fY3+7Jbz2/UGZgdo3MJ5+UjazxugCobC4gLejXNlFYOWU 077w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:references:from:openpgp:autocrypt :message-id:date:user-agent:mime-version:in-reply-to :content-language:content-transfer-encoding; bh=u0vp2kIEIpsHJ47ukBzO049cj5gTPTYN2WNmr7IsmoE=; b=O6O5HNu5dankPU07OkPB7jKre5WyTvFojOuESCXgk/w6he807iz6sXYrrNvOzQUB2Q qH8SWOcqphPEbigqraZ07NmgmGDFDQzL6MwCH3COqvXCuX00GW4Tin3Ip61FezwQADyT V7Acxzb/lKo3K7GtGZXK/fJygRaIRwxXji0DqjCyixjhoi03/YqaR6McTWbsLPaCqcoA X6xnqYsw5qyD6u5IW7tbj86wlH1M5DdxIPMh4llbNPDmJzS+DPY8YrT4OiY99hxeYnxu 613S0M07rItWnDld7XpPsXMD7tF8geD8hfodAf81QhEkThBeZmeNzmhwfIon46zKsB7e NuzA== X-Gm-Message-State: AOUpUlE18YYcR91gilvzz0oN1T3Y8PGSeCkqaKwjcKLDor/iBqe5A4wh /3Y+aUIR35ojVzboc0RdpyaI5eQJ X-Google-Smtp-Source: AA+uWPx6TPuPEuFeyZbh1KLCOzV72WPqQZyYNENR8nYFZSQ7fu0vEJw1wdgyw7j8YhX4fIROn1s2aw== X-Received: by 2002:ac8:1bdc:: with SMTP id m28-v6mr21473713qtk.81.1534276714469; Tue, 14 Aug 2018 12:58:34 -0700 (PDT) Received: from mbp-eth.home ([177.53.86.172]) by smtp.gmail.com with ESMTPSA id e29-v6sm7227771qte.47.2018.08.14.12.58.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 14 Aug 2018 12:58:33 -0700 (PDT) Subject: Re: svn commit: r337814 - head/tests/sys/kqueue/libkqueue To: David Bright , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org References: <201808141931.w7EJV77D081255@repo.freebsd.org> From: Renato Botelho Openpgp: preference=signencrypt Autocrypt: addr=garga.bsd@gmail.com; prefer-encrypt=mutual; keydata= xsBNBFn4ZqUBCACxJRW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1hKOG6QHWRr4ml4HTD/gZ6TTfsrR+sktBNv/5ZRkcJNDVM+eOGagXkEUOVFe9KXynD 3KcZBbBKpwoaW5GK8OglKJt8ggUfc78CG1xk4b5nL8QCk0CBrC6VPPOYvXTpYSTHmx1QkElm 1iNu1Tc5ccvcyAwTswARAQABwsB8BBgBCgAmFiEExxiLNMqsn7yXmTy7W54Ew5ZrhhoFAln4 ZqUCGwwFCQWjmoAACgkQW54Ew5ZrhhoH3wf+KuIeDyvIJOui+0C5FD5r44Bwkj/SAUVUerfp 0qtRktc+BZoSifPs3Rqjh/PpwRvLTuJnSsiqWLz8NCTThogRzVqEcQHqZR3vOjtYM60sjYJ+ BGQl/bjm1C/YtWEEmKs7mJc+02U8qJA4rbNKSRRRoz6XngnuN6YC0fkeD7c7rxRhOg6OWasZ JinB9+dO1IH7eZ5c97v518qSaLRp0T7I+FpEGOp7tTFHaepZWEnuojr5D6jI1MOEywy0EWJu 3m0TYlh935I8o7gLABqoHEmUeW7JK7r91SZaFnr8zQ6XOAxkPh50uFMTNtNZTnM7k1pRv5Ov fms0VzARITYzTwmpDQ== Message-ID: <98e8803a-1677-066a-6e50-a0183bd93f53@gmail.com> Date: Tue, 14 Aug 2018 16:58:30 -0300 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <201808141931.w7EJV77D081255@repo.freebsd.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 14 Aug 2018 19:58:36 -0000 On 14/08/18 16:31, David Bright wrote: > Author: dab > Date: Tue Aug 14 19:31:06 2018 > New Revision: 337814 > URL: https://svnweb.freebsd.org/changeset/base/337814 > > Log: > Fix several (more) memory leaks. > > A follow-up to r337812 to catch a couple more memory leaks that should > have been included in that change. > > Reported by: Coverity > CID: 1296064, 1296067 (for real this time) > MFC after: 3 days > X-MFC-with: r337812 > Sponsored by: Dell EMC > > Modified: > head/tests/sys/kqueue/libkqueue/main.c > > Modified: head/tests/sys/kqueue/libkqueue/main.c > ============================================================================== > --- head/tests/sys/kqueue/libkqueue/main.c Tue Aug 14 19:21:31 2018 (r337813) > +++ head/tests/sys/kqueue/libkqueue/main.c Tue Aug 14 19:31:06 2018 (r337814) > @@ -235,10 +235,14 @@ kevent_add(int kqfd, struct kevent *kev, > intptr_t data, > void *udata) > { > + char *kev_str; > + > EV_SET(kev, ident, filter, flags, fflags, data, NULL); > if (kevent(kqfd, kev, 1, NULL, 0, NULL) < 0) { > - printf("Unable to add the following kevent:\n%s\n", > - kevent_to_str(kev)); > + kev_str = kevent_to_str(kev); It seems that this line is indented with spaces instead of TABs > + printf("Unable to add the following kevent:\n%s\n", > + kev_str); > + free(kev_str); > err(1, "kevent(): %s", strerror(errno)); > } > } > @@ -246,6 +250,9 @@ kevent_add(int kqfd, struct kevent *kev, > void > kevent_cmp(struct kevent *k1, struct kevent *k2) > { > + char *kev1_str; > + char *kev2_str; > + > /* XXX- > Workaround for inconsistent implementation of kevent(2) > */ > @@ -258,8 +265,12 @@ kevent_cmp(struct kevent *k1, struct kevent *k2) > k1->data != k2->data || k1->udata != k2->udata || > k1->ext[0] != k2->ext[0] || k1->ext[1] != k2->ext[1] || > k1->ext[0] != k2->ext[2] || k1->ext[0] != k2->ext[3]) { > + kev1_str = kevent_to_str(k1); Same here > + kev2_str = kevent_to_str(k2); > printf("kevent_cmp: mismatch:\n %s !=\n %s\n", > - kevent_to_str(k1), kevent_to_str(k2)); > + kev1_str, kev2_str); > + free(kev1_str); > + free(kev2_str); > abort(); > } > } > _______________________________________________ > svn-src-head@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" > -- Renato Botelho