>> + errno = EINVAL; >> + return -1; > > ... I'm more concerned about this new error path. How can this happen ? >
As far as I can tell, the flags come from the client without any intermediate error checking. Since the Darwin constants do not match the Linux constants (which have the same numerical values as the 9p constants), we need to perform this checking/translation somewhere to ensure correct behavior. Is there a more appropriate place to put this check?