Change to natSystem.cc

'David Scott Urban urban@ast.lmco.com
Sat Apr 1 00:00:00 GMT 2000


I added this change to natSystem.cc to use overload resolution to find out the 
signature of getpwuid_r on HP's running HPUX 10.20.
The output was generated using the following command:
 diff -u natSystem.cc.old natSystem.cc > natSystem.patch
 
The file is located in the following directory:
 libgcj-snapshot-2000年01月07日/libjava/java/lang/
 
Since I have not applied any patches or worked on libgcj, I include it here so 
that someone could apply it properly and update whatever documentation is 
necessary.
Scott Urban
------------------------------ diff out ----------------------------------------
--- natSystem.cc.old	Tue Jan 11 08:25:34 2000
+++ natSystem.cc	Tue Jan 11 08:25:47 2000
@@ -205,6 +205,17 @@
 return getpwuid_r (user_id, pwd_r, buf_r, len_r, pwd_entry);
 }
 
+/* This is used on HPUX 10.20 */ 
+template <typename T_uid, typename T_passwd, typename T_buf, typename T_len>
+static inline int
+getpwuid_adaptor(int (*getpwuid_r)(T_uid user_id, T_passwd *pwd_r,
+					 T_buf *buf_r, T_len len_r),
+		 uid_t user_id, struct passwd *pwd_r,
+		 char *buf_r, size_t len_r, struct passwd **pwd_entry)
+{
+ return getpwuid_r (user_id, pwd_r, buf_r, len_r);
+}
+
 /* This is used on IRIX 5.2. */
 template <typename T_uid, typename T_passwd, typename T_buf, typename T_len>
 static inline int


More information about the Java mailing list

AltStyle によって変換されたページ (->オリジナル) /