[Samba] smbldap-tools Perl error (FreeBSD)

Per olof Ljungmark peo at intersonic.se
Wed Apr 27 14:27:14 GMT 2005


Gavin Henry wrote:
> <quote who="Per olof Ljungmark">
> 
>>Gavin Henry wrote:
>>
>>><quote who="Per olof Ljungmark">
>>>
>>>>smbldap-tools 0.8.7
>>>>FreeBSD 5.4-RC2
>>>>Samba 3.1.14
>>>>Perl 5.8.2
>>>>
>>>>When I try to use any of the tools, the following message appears. Any
>>>>hints on how to fix it are welcome.
>>>>
>>>>Bareword "print_banner" not allowed while "strict subs" in use at
>>>>/usr/local/sbin/smbldap-useradd line 43.
>>>>Execution of /usr/local/sbin/smbldap-useradd aborted due to compilation
>>>>errors.
>>>>
>>>
>>>They've probably missed a $ off of print_banner. Have you looked at line
>>>43?
>>>
>>
>>Hi Gavin,
>>
>>42 if ( (!$ok) || (@ARGV < 1) || ($Options{'?'}) ) {
>>43 print_banner;
>>44 print "Usage: $0 [-awmugdsckABCDEFGHMNPST?] username\n";
>>
>>Adding a "$" does not change much, however, if I comment out
>>"use strict;" it works. Now, what would be the problem with commenting
>>that out? I suspect this could be FBSD-specific.
> 
> 
> Ah, I've just looked at the code in smbldap_tools.pm. It's a call to the
> print_banner subroutine
> (http://cvs.idealx.org/cgi-bin/cvsweb/samba/smbldap-tools/smbldap_tools.pm?rev=1.54&content-type=text/x-cvsweb-markup&only_with_tag=v0-8-7)
> 
> 
> Add a & on the front of it:
> 
> 42 if ( (!$ok) || (@ARGV < 1) || ($Options{'?'}) ) {
> 43 &print_banner;
> 44 print "Usage: $0 [-awmugdsckABCDEFGHMNPST?] username\n";
> 
> 
> This doesn't appear to be fixed in version 0.8.8, so it might be something
> else.
> 
Then it is something else.


More information about the samba mailing list