[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH v1 3/3] xentrace: close output file in the function which opened it


  • To: xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Olaf Hering <olaf@xxxxxxxxx>
  • Date: Fri, 26 May 2023 09:29:16 +0200
  • Arc-authentication-results: i=1; strato.com; arc=none; dkim=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; t=1685086176; s=strato-dkim-0002; d=strato.com; h=References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Cc:Date: From:Subject:Sender; bh=S9fPMSqhE3ipoGZSZM4sNJyNsCfbZYCsqL8IUbcARXw=; b=aDOvrs9KzVLHyoDJ3Z+DvNde7Ddzq5Va3a1UbIrTZHuLnM4MzMrsvGQyUsYeJ/jNul wIrsTMXKxX2XLQ/uM9ZV/dP5KxiJEW48CjkFU5cQzU25D9n4YFDRoTsz3Q3EZlWu+f8X PMxJY/SsqTTXNwlz0ZaQ8UcgSTLnGoDURmAISgI4lQNFR3ZwI4nRXXXyqDZ9mnM98Cu8 6IqzBa2zq2du2jWpLLAe8qaFeaLuCnRdhh3L5jdOkyCPAEvXtXeZtn81NSmh2xAcS21d LdSoljnzprqbMT1KzGgdCHvF9N5fSxdszYqKweq59DxOM4N5rAWDwHn15WbKA/MgLDq2 2Tzg==
  • Arc-seal: i=1; a=rsa-sha256; t=1685086176; cv=none; d=strato.com; s=strato-dkim-0002; b=RAqu1yHSHxgRyjWc+mh6lftf8lCD1fl4SAElcfkzB2KkjlTPYR1UmDbkHSJbibZKn4 CSxDWsO2eMx2cmAMEOmbT3svp/tOC+mxaa89Y06r2FOUS3vJvRAYWhEOTzjHaBCFbM59 xQ8flx0m89L7ZEphGyRlsg26r/7nwmEmJpWjJ4fLTOE55tYrdCPGQgSPmnUFkURKI3Zj 4RHcbMpsc+h6z3UquEe2k7UCECE/rB9U664p5n6zozLaDUP/45qpKb1lqSLxWXOZUsfR OKtkanyZLfXuI/2sCkgYozt3kRIJAdGmMIzB9cZjvB6raihuvzT6TuEPm4458avyXb80 PtVQ==
  • Cc: George Dunlap <george.dunlap@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxxx>
  • Delivery-date: Fri, 26 May 2023 07:29:43 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Signed-off-by: Olaf Hering <olaf@xxxxxxxxx>
---
 tools/xentrace/xentrace.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/xentrace/xentrace.c b/tools/xentrace/xentrace.c
index a073cab26d..3548255123 100644
--- a/tools/xentrace/xentrace.c
+++ b/tools/xentrace/xentrace.c
@@ -794,7 +794,6 @@ static void monitor_tbufs(void)
     free(meta);
     free(data);
     /* don't need to munmap - cleanup is automatic */
-    close(outfd);
 }
 
 
@@ -1225,6 +1224,7 @@ int main(int argc, char **argv)
 
     monitor_tbufs();
 
+    close(outfd);
     return 0;
 }
 



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.