To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76159
------- Additional comments from [EMAIL PROTECTED] Wed Apr 11 16:16:00 +0000 2007 ------- >> 1.0 Standard platforms have _SC_GETPW_R_SIZE_MAX defined in >> unistd.h, and sysconf(_SC_GETPW_R_SIZE_MAX) either (a) returns a >> non-negative value or (b) returns -1 and leaves errno unchanged. >> Does any FreeBSD or OS X version fall in this category? > > Mac OS X 10.4 aka Tiger : > > - has _SC_GETPW_R_SIZE_MAX defined in unistd.h > - sysconf(_SC_GETPW_R_SIZE_MAX) returns -1 > - leaves errno unchanged ( returns 0 ) So Tiger *does* fall into the standard category. Fine! >> 1.2 Allegedly, some platforms have _SC_GETPW_R_SIZE_MAX defined in >> unistd.h, but sysconf(_SC_GETPW_R_SIZE_MAX) returns -1 and sets >> errno=EINVAL. Is that really true? Does any FreeBSD or OS X >> version fall in this category? > > Mac OS X 10.3 aka Panther has not _SC_GETPW_R_SIZE_MAX defined in > unistd.h, but we used 71 until now, in issue #i64769# , and nobody > cried. > > So once we admit _SC_GETPW_R_SIZE_MAX is equal to 71 , > > - sysconf(_SC_GETPW_R_SIZE_MAX) returns -1 > - errno returns 22 ( EINVAL) on Mac OS X 10.3 aka Panther No! We should not define the missing _SC_GETPW_R_SIZE_MAX to 71 (which leads to funky nonsense results), but just accept that there is no _SC_GETPW_R_SIZE_MAX (as we will do with the proposed patch). So, Panther is the 1.1 category, not the 1.2 category (and I hope no other OS is the 1.2 category, either, but it would be great if somebody could confirm that no FreeBSD is the 1.2 category). >> 3 In i76159_new_Implsec_macosx2.diff, >> +enum Result { KNOWN=0, UNKNOWN=1, ERROR=2 }; >> +typedef short Result; > >> is bad and should really be +enum Result { KNOWN, UNKNOWN, ERROR }; >> > > Don't know the mistake I did, because it does not work without the > typedef : I got a parser error on both Mac OS X 10.4 and 10.3, no > type is defined for Result, and Result is casted in "int" with a > warning. The parser error should go away with the "static enum Result sysconf_SC..." fix I mentioned. > BTW : shouldn't n be intialized too, no ? (got a warning ) Yes, "size_t n = 0;" is probably necessary to silence compiler warnings. (Again, I did not actually try the code I posted.) --------------------------------------------------------------------- Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]