Unix SMB/Netbios implementation.
Version 1.9.
status reporting
- Copyright (C) Andrew Tridgell 1994-1997
+ Copyright (C) Andrew Tridgell 1994-1998
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
charset_initialise();
DEBUGLEVEL = 0;
- dbf = fopen("/dev/null","w");
+ dbf = stderr;
if (getuid() != geteuid()) {
printf("smbstatus should not be run setuid\n");
get_myname(myhostname, NULL);
- if (!lp_load(servicesf,False)) {
+ if (!lp_load(servicesf,False,False,False)) {
fprintf(stderr, "Can't load %s - run testparm to debug it\n", servicesf);
return (-1);
}
{
if (fread(&crec,sizeof(crec),1,f) != 1)
break;
+ if (crec.cnum == -1) continue;
if ( crec.magic == 0x280267 && process_exists(crec.pid)
&& Ucrit_checkUsername(uidtoname(crec.uid)) /* added by OH */
)