ports/104234: Problem with mounting a smb share out of linneighborhood
Bernhard Höckner
berhoeckner at gmx.at
Tue Oct 10 00:10:26 UTC 2006
>Number: 104234
>Category: ports
>Synopsis: Problem with mounting a smb share out of linneighborhood
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue Oct 10 00:10:24 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Bernhard Höckner
>Release: 6.1
>Organization:
private
>Environment:
FreeBSD yuri 6.1-RELEASE-p5 FreeBSD 6.1-RELEASE-p5 #0: Mon Sep 4 16:33:03 CEST 2006 yuri at yuri:/usr/obj/usr/src/sys/KERNEL_2205 i386
>Description:
I had a problem with mounting shares in my network out of LinNeighborhood: The smb shares were found, and could be mounted with mount_smbfs from the commandline, but not from within LinNeighborhood. The problem was a commandline option used of LinNeighborhood without an argument.
The problem was that a pointer to a string wasn't checked if the pointer was set properly, so it could happen that an empty string was used as argument.
>How-To-Repeat:
>Fix:
Just checks if the pointer is set properly.
--- smbmount.c.orig Mon Oct 9 18:55:21 2006
+++ smbmount.c Mon Oct 9 19:15:03 2006
@@ -450,9 +450,11 @@
argv[++argnr]=num3;
argv[++argnr]="-g";
argv[++argnr]=num4;
- argv[++argnr]="-I";
- strcpy(tmp, ipaddr);
- argv[++argnr]=tmp;
+ if( *ipaddr)
+ {
+ argv[++argnr]="-I";
+ argv[++argnr]=ipaddr;
+ }
if (*group_name)
{
argv[++argnr]="-W";
Patch attached with submission follows:
--- smbmount.c.orig Mon Oct 9 18:55:21 2006
+++ smbmount.c Mon Oct 9 19:15:03 2006
@@ -450,9 +450,11 @@
argv[++argnr]=num3;
argv[++argnr]="-g";
argv[++argnr]=num4;
- argv[++argnr]="-I";
- strcpy(tmp, ipaddr);
- argv[++argnr]=tmp;
+ if( *ipaddr)
+ {
+ argv[++argnr]="-I";
+ argv[++argnr]=ipaddr;
+ }
if (*group_name)
{
argv[++argnr]="-W";
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list