The Samba-Bugzilla – Attachment 4819 Details for
Bug 6692
mount.cifs segfault
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
patch 2 -- cherry-pick correct patch from master
0002-s3-mount.cifs-make-mount.cifs-V-print-the-versio.patch (text/plain), 1.82 KB, created by
Jeff Layton
on 2009-10-08 09:48:37 UTC
(
hide
)
Description:
patch 2 -- cherry-pick correct patch from master
Filename:
MIME Type:
Creator:
Jeff Layton
Created:
2009-10-08 09:48:37 UTC
Size:
1.82 KB
patch
obsolete
>From f3f6202392065ab5c5e27f25d9b572af84cd599d Mon Sep 17 00:00:00 2001 >From: Michael Adam <obnox@samba.org> >Date: Thu, 8 Oct 2009 10:44:48 -0400 >Subject: [PATCH] s3:mount.cifs: make "mount.cifs -V" print the version, not usage. > >(cherry-picked from d7ca4997017e86b6f23ced64f1f1672bfb15716b) > >Also make "mount.cifs -h" not exit with error exit code but with return code 0. > >Michael >--- > source/client/mount.cifs.c | 33 ++++++++++++++++++++++++++++----- > 1 files changed, 28 insertions(+), 5 deletions(-) > >diff --git a/source/client/mount.cifs.c b/source/client/mount.cifs.c >index bb40a8c..0add7a8 100644 >--- a/source/client/mount.cifs.c >+++ b/source/client/mount.cifs.c >@@ -1036,6 +1036,14 @@ uppercase_string(char *string) > return 1; > } > >+static void print_cifs_mount_version(void) >+{ >+ printf("mount.cifs version: %s.%s%s\n", >+ MOUNT_CIFS_VERSION_MAJOR, >+ MOUNT_CIFS_VERSION_MINOR, >+ MOUNT_CIFS_VENDOR_SUFFIX); >+} >+ > int main(int argc, char ** argv) > { > int c; >@@ -1097,6 +1105,24 @@ int main(int argc, char ** argv) > exit(EX_SYSERR); > } > mountpoint = argv[2]; >+ } else if (argc == 2) { >+ if ((strcmp(argv[1], "-V") == 0) || >+ (strcmp(argv[1], "--version") == 0)) >+ { >+ print_cifs_mount_version(); >+ exit(0); >+ } >+ >+ if ((strcmp(argv[1], "-h") == 0) || >+ (strcmp(argv[1], "-?") == 0) || >+ (strcmp(argv[1], "--help") == 0)) >+ { >+ mount_cifs_usage(); >+ exit(0); >+ } >+ >+ mount_cifs_usage(); >+ exit(EX_USAGE); > } else { > mount_cifs_usage(); > exit(EX_USAGE); >@@ -1153,11 +1179,8 @@ int main(int argc, char ** argv) > case 'v': > ++verboseflag; > break; >- case 'V': >- printf ("mount.cifs version: %s.%s%s\n", >- MOUNT_CIFS_VERSION_MAJOR, >- MOUNT_CIFS_VERSION_MINOR, >- MOUNT_CIFS_VENDOR_SUFFIX); >+ case 'V': >+ print_cifs_mount_version(); > exit (0); > case 'w': > flags &= ~MS_RDONLY; >-- >1.6.0.6 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Flags:
jlayton
:
review?
(
sfrench
)
Actions:
View
Attachments on
bug 6692
:
4818
| 4819