Mailinglist Archive: opensuse-bugs (6564 mails)

< Previous Next >
[Bug 528272] New: nbd-2.9.13-1.4: missing call to close
  • From: bugzilla_noreply@xxxxxxxxxx
  • Date: Wed, 5 Aug 2009 02:31:11 -0600
  • Message-id: <bug-528272-21960@xxxxxxxxxxxxxxxxxxxxxxxx/>

Summary: nbd-2.9.13-1.4: missing call to close
Classification: openSUSE
Product: openSUSE 11.2
Version: Factory
Platform: All
OS/Version: openSUSE 11.1
Status: NEW
Severity: Normal
Priority: P5 - None
Component: Other
AssignedTo: bnc-team-screening@xxxxxxxxxxxxxxxxxxxxxx
ReportedBy: dcb314@xxxxxxxxxxx
QAContact: qa@xxxxxxx
Found By: ---

I just had a look at factory package nbd-2.9.13-1.4

For source code file nbd-2.9.13/nbd-client.c
around line 60 is the source code for the
function check_conn.

I notice the following line of code

if((fd=open(buf, O_RDONLY))<0) {

but I fail to find a matching call to close.
This seems to be a resource leak. Suggest code rework,
possibly by adding call to close.

Configure bugmail:
------- You are receiving this mail because: -------
You are on the CC list for the bug.

< Previous Next >