Print

Print


1. It seems that XrdPosix.hh and XrdPosixXrootd.h both have the same  
#if !defined value at the top of the file. They really ought to be  
separate.

2. To include XrdPosix.hh one must include a bunch of system  
includes. I think
#include <sys/types.h>
#include <dirent.h>
#include <fcntl.h>

would just about do it.

3. If I include XrdPosix.hh it commits evil by defining macros for  
read, write, open, etc, so my code

     int Foo::read(void * buffer, size_t sz)
     {
         return XrdPosix_read(fd_, buffer, sz);
     }

cannot compile because it tries to do a macro substition on the read  
in Foo::read.
This is evil. The macros should be in a separate file from the  
XrdPosix_XXX definitions so that only those that really want them  
actually get them.

--
Gregory J. Sharp                   email: [log in to unmask]
Wilson Synchrotron Laboratory      url: http://www.lepp.cornell.edu/ 
~gregor
Cornell University                 ph:  +1 607 255 4882
Ithaca, NY 14853                   fax: +1 607 255 8062