apr-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brad Nicholes" <BNICHO...@novell.com>
Subject Re: [PATCH] unused code in user/netware/userinfo.c
Date Wed, 24 Nov 2004 00:28:00 GMT
   APR is a cross platform library.  The code is there because whether
the functions are actually implemented or not, the API must exist in
order for APR on NetWare to remain API compatible with APR on other
platforms for porting purposes.   Since this functionality can not be
implemented today on NetWare is the reason why they return the value
APR_ENOTIMPL.  There already is an Open Source port of BASH for NetWare
which, if Apache were running within a BASH shell, would allow for
UID/GID functionality.  So yes it could be implemented in the
foreseeable future.  As for the getpwnam_safe() static function, whether
it stays or goes doesn't really matter.  It was left there after the
API's were stubbed out for NetWare and if or when these APR functions
are ever actually implemented on NetWare, it may become necessary


>>> julianfoad@btopenworld.com Tuesday, November 23, 2004 3:22:17 PM
Brad Nicholes wrote:
>    You are right, it is dead code for now.  The reason why it is
> is because this file is just a stub rip-off of the Unix
> It is just waiting for the day when the NetWare OS supports UID/GID
> running applications and services.  On the NetWare OS applications
> services don't run as a user, they just run.  Therefore the
> APIs like getuid(), getgid() and getpwnam() don't exist on NetWare. 
> Even if they did, they wouldn't return anything useful.  So for now,
> this is just a stub implementation.

You seem to be implying that there is a reason for this code to exist:
Netware is likely to gain UID/GID support in the forseeable future and
this code will be useful when it does, and that having the code already
will be considerably more useful than a programmer having to write it
again or 
copy it from the Unix implementation.  Is all of that correct?

- Julian

View raw message