Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
SUSE:SLE-12-SP2:GA
ipxrip
ipxripd-0.7-2.6kernel-fix.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File ipxripd-0.7-2.6kernel-fix.diff of Package ipxrip
--- ipxkern.c +++ ipxkern.c @@ -31,6 +31,7 @@ #endif #include <netinet/in.h> #include "ipxkern.h" +#include <sys/utsname.h> #define MAX_IFC (256) @@ -54,8 +55,16 @@ { FILE *ipx_route; char buf[512]; + struct utsname u; - ipx_route = fopen("/proc/net/ipx_route", "r"); + if (uname(&u) != 0) { + sprintf(ipx_err_string, "call uname: %s", + strerror(errno)); + return -1; + } + + ipx_route = fopen(strncmp(u.version, "2.4", 3) == 0 ? + "/proc/net/ipx_route" : "/proc/net/ipx/route", "r"); if (ipx_route == NULL) { @@ -112,8 +121,16 @@ { FILE *ipx_ifc; char buf[512]; + struct utsname u; + + if (uname(&u) != 0) { + sprintf(ipx_err_string, "call uname: %s", + strerror(errno)); + return -1; + } - ipx_ifc = fopen("/proc/net/ipx_interface", "r"); + ipx_ifc = fopen(strncmp(u.version, "2.4", 3) == 0 ? + "/proc/net/ipx_interface" : "/proc/net/ipx/interface", "r"); if (ipx_ifc == NULL) {
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor