summaryrefslogtreecommitdiff
path: root/ncpfs/01-linux3.0_uname.patch
diff options
context:
space:
mode:
Diffstat (limited to 'ncpfs/01-linux3.0_uname.patch')
-rw-r--r--ncpfs/01-linux3.0_uname.patch20
1 files changed, 20 insertions, 0 deletions
diff --git a/ncpfs/01-linux3.0_uname.patch b/ncpfs/01-linux3.0_uname.patch
new file mode 100644
index 00000000..6818af87
--- /dev/null
+++ b/ncpfs/01-linux3.0_uname.patch
@@ -0,0 +1,20 @@
+diff -aur ncpfs-2.2.6.org/sutil/ncpm_common.c ncpfs-2.2.6/sutil/ncpm_common.c
+--- ncpfs-2.2.6.org/sutil/ncpm_common.c 2011-08-23 16:45:11.000000000 +0200
++++ ncpfs-2.2.6/sutil/ncpm_common.c 2011-08-23 16:52:26.049972551 +0200
+@@ -245,13 +245,13 @@
+
+ static int getmountver(void) {
+ struct utsname name;
+- int maj, mid, rev;
++ int maj = 0, mid = 0, rev = 0;
+ int ver;
+
+ if (uname(&name)) {
+ errexit(1, _("Cannot get kernel release\n"));
+ }
+- if (sscanf(name.release, "%d.%d.%d", &maj, &mid, &rev) != 3) {
++ if (sscanf(name.release, "%d.%d-ARCH", &maj, &mid) != 2) {
+ errexit(2, _("Cannot convert kernel release \"%s\" to number\n"), name.release);
+ }
+ ver = maj*0x10000 + mid*0x100 + rev;
+