rpms/wlassistant/devel wlassistant-0.5.7-fd_cloexec.patch, NONE, 1.1 wlassistant.desktop, 1.1, 1.2 wlassistant.spec, 1.9, 1.10
Tom Callaway (spot)
fedora-extras-commits at redhat.com
Mon Jul 23 14:52:14 UTC 2007
Author: spot
Update of /cvs/extras/rpms/wlassistant/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv23226/devel
Modified Files:
wlassistant.desktop wlassistant.spec
Added Files:
wlassistant-0.5.7-fd_cloexec.patch
Log Message:
Try to fix bz 243509
wlassistant-0.5.7-fd_cloexec.patch:
--- NEW FILE wlassistant-0.5.7-fd_cloexec.patch ---
diff -up wlassistant-0.5.7/src/watools.cpp.BAD wlassistant-0.5.7/src/watools.cpp
--- wlassistant-0.5.7/src/watools.cpp.BAD 2007-07-23 10:13:15.000000000 -0500
+++ wlassistant-0.5.7/src/watools.cpp 2007-07-23 10:16:48.000000000 -0500
@@ -23,6 +23,7 @@
#include <unistd.h> //provides readlink
#include <dirent.h>
#include <stdio.h> //to get values from /sys
+#include <fcntl.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <arpa/inet.h> //inet_ntoa
@@ -178,6 +179,13 @@ int WATools::availableNetworks( const ch
_ifname = ifname;
if (iw_socket<0)
iw_socket = iw_sockets_open(); //get kernel socket
+ int flags;
+ flags = fcntl(iw_socket, F_GETFD);
+ if (flags == -1)
+ return 0;
+ flags |= FD_CLOEXEC;
+ if (fcntl(iw_socket, F_SETFD, flags) == -1)
+ return 0;
if (iw_socket<0)
return 0;
@@ -264,6 +272,13 @@ int WATools::doRequest( int request, str
_ifname = ifname;
if (iw_socket<0)
iw_socket = iw_sockets_open(); //get kernel socket
+ int flags;
+ flags = fcntl(iw_socket, F_GETFD);
+ if (flags == -1)
+ return 0;
+ flags |= FD_CLOEXEC;
+ if (fcntl(iw_socket, F_SETFD, flags) == -1)
+ return 0;
if (iw_socket<0)
return 0;
@@ -278,6 +293,13 @@ int WATools::doWirelessRequest( int requ
_ifname = ifname;
if (iw_socket<0)
iw_socket = iw_sockets_open(); //get kernel socket
+ int flags;
+ flags = fcntl(iw_socket, F_GETFD);
+ if (flags == -1)
+ return 0;
+ flags |= FD_CLOEXEC;
+ if (fcntl(iw_socket, F_SETFD, flags) == -1)
+ return 0;
if (iw_socket<0)
return 0;
@@ -292,6 +314,13 @@ int WATools::doWirelessStatisticsRequest
_ifname = ifname;
if (iw_socket<0)
iw_socket = iw_sockets_open();//get kernel socket
+ int flags;
+ flags = fcntl(iw_socket, F_GETFD);
+ if (flags == -1)
+ return 0;
+ flags |= FD_CLOEXEC;
+ if (fcntl(iw_socket, F_SETFD, flags) == -1)
+ return 0;
if (iw_socket<0)
return 0;
Index: wlassistant.desktop
===================================================================
RCS file: /cvs/extras/rpms/wlassistant/devel/wlassistant.desktop,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wlassistant.desktop 17 Sep 2005 21:31:56 -0000 1.1
+++ wlassistant.desktop 23 Jul 2007 14:51:42 -0000 1.2
@@ -7,6 +7,5 @@
Exec=/usr/sbin/wlassistant
Icon=/usr/share/icons/hicolor/32x32/apps/wlassistant.png
Type=Application
-Categories=Application;SystemSetup;System;
+Categories=Application;Settings
StartupNotify=true
-
Index: wlassistant.spec
===================================================================
RCS file: /cvs/extras/rpms/wlassistant/devel/wlassistant.spec,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- wlassistant.spec 23 May 2007 04:48:10 -0000 1.9
+++ wlassistant.spec 23 Jul 2007 14:51:42 -0000 1.10
@@ -1,6 +1,6 @@
Name: wlassistant
Version: 0.5.7
-Release: 2%{?dist}
+Release: 3%{?dist}
License: GPL
Group: Applications/System
Summary: Wireless network management tool
@@ -16,6 +16,7 @@
Requires(postun): desktop-file-utils
Requires: usermode, wireless-tools, net-tools, dhclient
Patch0: wlassistant-0.5.5-rpath.patch
+Patch1: wlassistant-0.5.7-fd_cloexec.patch
%description
Wireless Assistant (wlassistant) is a small application that allows you to
@@ -32,6 +33,7 @@
%prep
%setup -q
%patch0 -p1
+%patch1 -p1
%build
PARSED_OPT_FLAGS=`echo \'$RPM_OPT_FLAGS\' | sed "s/ /',/g" | sed "s/',/', '/g"`
@@ -85,6 +87,9 @@
%{_datadir}/icons/hicolor/32x32/apps/wlassistant.png
%changelog
+* Mon Jul 23 2007 Tom "spot" Callaway <tcallawa at redhat.com> 0.5.7-3
+- close file descriptors with FD_CLOEXEC, try to resolve bz 243509
+
* Wed May 23 2007 Christopher Aillon <caillon at redhat.com> 0.5.7-2
- Rebuild against newer libiw.so
More information about the fedora-extras-commits
mailing list