2 Build bugs on Sco openserver 5.05
Joe Doran
joed at dircon.co.uk
Fri Nov 3 12:03:30 GMT 2000
Hi,
Please excuse any incorrect formality as this is my first posting to the list.
I have come across two build bugs on a sco openserver platform and cannot
confirm if this is an issue for other builds at this time.
In smbd/reply.c there is a function called map_lock_offset() which is used if
the os does not support longlong types. This function cannot be found in any
library available to sco5 or on a linux box. Anyone got any idea where this
function has arisen from?
/*
* NT4.x seems to be broken in that it sends large file (64 bit)
* lockingX calls even if the CAP_LARGE_FILES was *not*
* negotiated. For boxes without large unsigned ints mangle the
* lock offset by mapping the top 32 bits onto the lower 32.
*/
if(IVAL(data,SMB_LARGE_LKOFF_OFFSET_HIGH(data_offset)) != 0) {
uint32 low = IVAL(data,SMB_LARGE_LKOFF_OFFSET_LOW(data_offset));
uint32 high = IVAL(data,SMB_LARGE_LKOFF_OFFSET_HIGH(data_offset));
uint32 new_low = 0;
if((new_low = map_lock_offset(high, low)) == 0) {
*err = True;
return (SMB_BIG_UINT)-1;
}
Also macro function S_ISSOCK() which appears to check permissions on a socket
in file nsswitch/wb_common.c does not exist in sco5 libraries, it appears to
be specific to bsd systems. Maybe should fstat or lstat be used on this to
return permissions instead of using macro?.
/* Check permissions on unix socket file */
if (!S_ISSOCK(st.st_mode) || (st.st_uid != 0)) {
return -1;
}
/* Connect to socket */
if ((established_socket = socket(AF_UNIX, SOCK_STREAM, 0)) == -1) {
return -1;
<EOT>
Joe Doran.
* To error is human,
to really mess things up takes
a mainframe,pc,network eh you'll need a ... *
More information about the samba-technical
mailing list