aboutsummaryrefslogtreecommitdiff
path: root/libjava/java/net
AgeCommit message (Collapse)AuthorFilesLines
2000-10-06natField.cc (BooleanClass): Don't define.Tom Tromey2-6/+4
* java/lang/reflect/natField.cc (BooleanClass): Don't define. * java/lang/reflect/natArray.cc (BooleanClass): Don't define. * java/lang/Class.h (Object): Added `class$' field. * java/lang/Object.h (Object): Added `class$' field. * defineclass.cc (ClassClass): Use `class$' form. (ClassObject): Likewise. * resolve.cc (ClassObject): Use `class$' form. (ObjectClass): Likewise. * interpret.cc (ClassError): Removed. * java/net/natPlainDatagramSocketImpl.cc (BooleanClass): Use `class$' form. (IntegerClass): Likewise. * java/net/natPlainSocketImpl.cc (BooleanClass): Use `class$' form. * java/lang/natClassLoader.cc (CloneableClass): Use `class$' form. (ObjectClass, ClassClass, VMClassLoaderClass, ClassLoaderClass, SerializableClass): Likewise. Include Serializable.h, Cloneable.h. * java/lang/natSystem.cc (SystemClass): Removed. (init_properties): Use `class$' form. * java/lang/natObject.cc (CloneableClass): Removed. (clone): Use `class$' form. * java/lang/natClass.cc (CloneableClass): Use `class$' form. (ObjectClass, ErrorClass, ClassClass, MethodClass, FieldClass, ConstructorClass): Likewise. * java/lang/reflect/natMethod.cc (ObjectClass): Use `class$' form. (ClassClass, VoidClass, ByteClass, ShortClass, CharacterClass, IntegerClass, LongClass, FloatClass, DoubleClass): Likewise. * java/io/natObjectInputStream.cc (ObjectClass): Use `class$' form. (ClassClass): Likewise. * include/jvm.h (StringClass): Use `class$' form. * prims.cc (ObjectClass): Removed. (_Jv_RunMain): Use `class$' form. (_Jv_AllocObject): Likewise. * jni.cc (ClassClass): Use `class$' form. (ThrowableClass): Likewise. (ObjectClass): Likewise. (MethodClass): Likewise. (ThreadGroupClass): Likewise. (NativeThreadClass): Likewise. * boehm.cc (ObjectClass): Removed. (ClassClass): Removed. (_Jv_MarkObj): Use `class$' form. * gcj/field.h (JvFieldIsRef): Use `class$' form. Include RawData.h. From-SVN: r36740
2000-09-08PropertyChangeEvent.java (serialVersionUID): Added.Warren Levy1-3/+27
* java/beans/PropertyChangeEvent.java (serialVersionUID): Added. * java/beans/PropertyVetoException.java (serialVersionUID): Added. * java/io/File.java (writeObject): Added. (readObject): Added. (serialVersionUID): Added. * java/io/ObjectOutputStream.java (writeObject): Initialized fieldsAlreadyWritten before recursion rather than after. * java/io/ObjectStreamClass.java (serialVersionUID): Added. * java/io/OptionalDataException.java (serialVersionUID): Added. (OptionalDataException): Made package private. * java/io/SyncFailedException.java (SyncFailedException): Removed default constructor to match spec. * java/lang/Boolean.java (serialVersionUID): Added. * java/lang/Byte.java (serialVersionUID): Added. * java/lang/Character.java (serialVersionUID): Added. * java/lang/Double.java (serialVersionUID): Added. * java/lang/Float.java (serialVersionUID): Added. * java/lang/Integer.java (serialVersionUID): Added. * java/lang/Long.java (serialVersionUID): Added. * java/lang/Number.java (serialVersionUID): Added. * java/lang/Short.java (serialVersionUID): Added. * java/lang/String.java (serialVersionUID): Added. * java/lang/ThreadDeath.java (ThreadDeath): Removed constructor to match spec. * java/lang/reflect/InvocationTargetException.java (serialVersionUID): Added. * java/net/URL.java (handler): Made transient. (hashCode): Added field for serialization, per spec. and use cached value if available. (serialVersionUID): Added. (URL): Initialize hashCode. (set): Adjust hashCode. (readObject): New Method to initialize the protocol handler when deserializing. (writeObject): New method. * java/text/BreakIterator.java: Removed 'implements Serializable'. * java/text/Collator.java: Removed 'implements Serializable'. * java/util/GregorianCalendar.java (serialVersionUID): Added. * java/util/Properties.java (serialVersionUID): Added. * java/util/Random.java (serialVersionUID): Added. (seed): Made private. (nextNextGaussian): Made private. (haveNextNextGaussian): Made private. * java/util/Stack.java (serialVersionUID): Added. * java/util/TimeZone.java (serialVersionUID): Added. * java/util/Vector.java (serialVersionUID): Added. Serialization mods. From-SVN: r36272
2000-09-06* java/net/natPlainDatagramSocketImpl.cc (mcastGrp): Fix typo.Bryce McKinlay1-1/+1
From-SVN: r36170
2000-09-05natPlainDatagramSocketImpl.cc: Change various `JvThrow' calls to `throw'.Bryce McKinlay3-80/+103
2000-09-05 Bryce McKinlay <bryce@albatross.co.nz> * java/net/natPlainDatagramSocketImpl.cc: Change various `JvThrow' calls to `throw'. (send): Undo last patch. Remove the label only. (mcastGrp): Ditto. * java/net/natPlainSocketImpl.cc: Change various `JvThrow' calls to `throw'. * java/net/natInetAdress.cc: Ditto. From-SVN: r36165
2000-09-05natIconv.cc (read): Remove unused local.Bryce McKinlay1-6/+0
2000-09-05 Bryce McKinlay <bryce@albatross.co.nz> * gnu/gcj/convert/natIconv.cc (read): Remove unused local. (write): Ditto. * gnu/gcj/runtime/FileDeleter.java (deleteOnExitNow): Check for null stack. Synchronize. * java/lang/fdlibm.h: #undef __P if previously defined. * java/lang/natSystem.cc (currentTimeMillis): Remove unused local. * java/net/natPlainDatagramSocketImpl.cc (send): Remove unreachable block. (mcastGrp): Ditto. From-SVN: r36158
2000-08-20URLClassLoader.java: Find the JarEntry via the JarFile.Anthony Green2-18/+19
Sun Aug 20 09:51:48 2000 Anthony Green <green@redhat.com> * java/net/URLClassLoader.java: Find the JarEntry via the JarFile. * java/net/JarURLConnection.java: getEntry doesn't take any arguments. Return null if element is null. * java/util/zip/ZipFile.java (getInputStream): Read the compressed size from the archive, not the inflated size. * java/util/jar/JarFile.java (getEntry): Don't recurse. Call java.util.zip.ZipFile.getEntry. * gij.cc (help): Change sourceware reference to sources.redhat.com. From-SVN: r35821
2000-08-11natPlainSocketImpl.cc (bind): Don't go to error case when errno not set.Tom Tromey2-15/+27
* java/net/natPlainSocketImpl.cc (bind): Don't go to error case when errno not set. (connect): Likewise. (accept): Likewise. (getOption): Likewise. * java/net/natPlainDatagramSocketImpl.cc (bind): Don't go to error case when errno not set. (peek): Likewise. (send): Likewise. (receive): Likewise. (mcastGrp): Likewise. (setOption): Likewise. (getOption): Likewise. From-SVN: r35617
2000-08-10Connection.java (gotHeaders): Removed.Bryce McKinlay1-9/+17
2000-08-10 Bryce McKinlay <bryce@albatross.co.nz> John Stracke <francis@ecal.com> * gnu/gcj/protocol/http/Connection.java (gotHeaders): Removed. (connect): Don't falsely claim HTTP/1.1 compliance. Call getHttpHeaders(). (disconnect): Don't unset connected flag. (getHeaderField (String)): Call connect() if not connected. (getHeaderField (int)): Ditto. (getHeaderFieldKey): Ditto. (getHttpHeaders): Don't call connect(). * java/net/HttpURLConnection.java (instanceFollowRedirects, gotResponseVals): New fields. (getResponseCode): Call getResponseVals() conditionally. (getResponseMessage): Ditto. (getResponseVals): Call connect(). Don't throw FileNotFoundException. From-SVN: r35603
2000-08-02Makefile.in: Rebuilt.Tom Tromey2-15/+5
* Makefile.in: Rebuilt. * Makefile.am (libgcj_la_SOURCES): Added posix.cc. * java/net/natPlainSocketImpl.cc: Include posix.h. (accept): Use _Jv_select. * java/net/natPlainDatagramSocketImpl.cc: Include posix.h. (receive): Use _Jv_select. * java/io/natFileDescriptorPosix.cc: Include posix.h. (available): Use _Jv_select. * java/lang/natSystem.cc: Include posix.h. (currentTimeMillis): Use _Jv_gettimeofday. * include/posix.h: New file. * posix.cc: New file. From-SVN: r35435
2000-06-27PropertyChangeEvent.java (oldVal): Renamed to oldValue.Warren Levy1-2/+2
* java/beans/PropertyChangeEvent.java (oldVal): Renamed to oldValue. (newVal): Renamed to newValue. * java/beans/PropertyVetoException.java (changeEvent): Renamed to evt. * java/beans/beancontext/BeanContextServiceRevokedEvent.java (revokeNow): Renamed to invalidateRefs. * java/io/OptionalDataException.java: Updated FIXME. (eof): New placeholder field. (length); Ditto. * java/io/WriteAbortedException.java (message): Made transient. * java/lang/ClassNotFoundException.java: Updated comments for JDK 1.2. * java/lang/Throwable.java (stackTrace): Made transient. * java/net/InetAddress.java: Made Serializable. * java/security/KeyPair.java: Made Serializable. * java/security/Provider.java: Replaced with Classpath version that implements serialization and proper methods. * java/text/ChoiceFormat.java (strings): Renamed to choiceFormats. (limits): Renamed to choiceLimits. Serialization changes per: http://java.sun.com/products/jdk/1.2/docs/api/serialized-form.html From-SVN: r34726
2000-05-19Jumbo patch:Tom Tromey1-0/+14
* Imported beans and serialization * Updated IA-64 port * Miscellaneous bug fixes From-SVN: r34028
2000-05-04Locale.java (Locale): Don't explicitly check for null.Tom Tromey2-16/+2
* java/util/Locale.java (Locale): Don't explicitly check for null. * java/util/Hashtable.java (containsKey): Don't explicitly check for null. (get): Likewise. * java/util/BitSet.java (and, or, xor): Don't explicitly check for null. * java/util/zip/ZipEntry.java (ZipEntry): Don't explicitly check for null. * java/text/StringCharacterIterator.java (StringCharacterIterator): Don't check for null. * java/text/ChoiceFormat.java (setChoices): Don't explicitly check for null pointer. * java/net/MulticastSocket.java (joinGroup): Don't explicitly check for null pointer. (leaveGroup): Likewise. * java/net/DatagramPacket.java (DatagramPacket): Removed erroneous comment. (setData): Likewise. * java/lang/ThreadGroup.java (ThreadGroup): Don't explicitly check for `p==null'. From-SVN: r33671
2000-04-21re GNATS libgcj/15 (_REENTRANT should be defined more consistently)Tom Tromey1-5/+1
Fix for PR libgcj/15: * java/util/natGregorianCalendar.cc (_REENTRANT, _POSIX_PTHREAD_SEMANTICS): Don't define. * java/net/natInetAddress.cc (_REENTRANT): Don't define. * java/lang/natSystem.cc (_REENTRANT, _POSIX_PTHREAD_SEMANTICS): Don't define. * java/io/natFile.cc (_REENTRANT, _POSIX_PTHREAD_SEMANTICS): Don't define. * configure: Rebuilt. * configure.in: If using POSIX threads, define _REENTRANT if needed. Define _POSIX_PTHREAD_SEMANTICS. Don't define GETHOSTBYNAME_R_NEEDS_REENTRANT. From-SVN: r33318
2000-04-11ObjectStreamException.java: New file.Warren Levy1-2/+2
* java/io/ObjectStreamException.java: New file. * java/io/OptionalDataException.java: New file. * java/io/StreamCorruptedException.java: New file. * java/math/BigDecimal.java: New file. * java/sql/CallableStatement.java: New file. * java/sql/Connection.java: New file. * java/sql/DataTruncation.java: New file. * java/sql/DatabaseMetaData.java: New file. * java/sql/Date.java: New file. * java/sql/Driver.java: New file. * java/sql/DriverManager.java: New file. * java/sql/DriverPropertyInfo.java: New file. * java/sql/PreparedStatement.java: New file. * java/sql/ResultSet.java: New file. * java/sql/ResultSetMetaData.java: New file. * java/sql/SQLException.java: New file. * java/sql/SQLWarning.java: New file. * java/sql/Statement.java: New file. * java/sql/Time.java: New file. * java/sql/Timestamp.java: New file. * java/sql/Types.java: New file. * Makefile.am: Added above new files. * Makefile.in: Rebuilt. * mauve-libgcj: Turned on java.math, java.sql and java.security tests. * java/net/MulticastSocket.java (MulticastSocket): Pass values a la DatagramSocket constructor instead of null. java.sql is JDK 1.1 Compliant From-SVN: r33077
2000-03-15[multiple changes]Tom Tromey3-0/+34
2000-03-15 Tom Tromey <tromey@cygnus.com> * java/io/natFileDescriptorWin32.cc (winerr): Now static. * prims.cc (win32_exception_handler): Reformatted. * include/win32-threads.h (_Jv_HaveCondDestroy): New define. (_Jv_HaveMutexDestroy): Likewise. 2000-03-15 Jon Beniston <jb7216@bristol.ac.uk> * java/io/natFileDescriptorWin32.cc: New file. * java/io/natFileWin32.cc: New file. * java/net/natInetAddress.cc: Added conditional inclusion of Windows / Winsock headers. * java/net/natPlainDatagramSocketImpl.cc: Added conditional inclusion of Windows / Winsock headers. * java/net/natPlainSocketImpl.cc: Added conditional inclusion of Windows / Winsock headers. * include/win32-signal.h: New file. * include/win32-threads.h: New file. * win32-threads.cc: New file. * exception.cc (win32_get_restart_frame): New function. * prims.cc (win32_exception_handler): New function. (main_init) Performs Winsock initialisation. (main_init) Installs exeception handler. From-SVN: r32567
2000-03-07All files: Updated copyright information.Tom Tromey35-35/+35
* All files: Updated copyright information. * COPYING: New file. * COPYING.LIB: Removed. * LIBGCJ_LICENSE: We now use GPL + special exception. From-SVN: r32387
2000-03-05DatagramSocket.java (DatagramSocket(int,InetAddress)): Handle null addresses.Warren Levy1-2/+2
* java/net/DatagramSocket.java(DatagramSocket(int,InetAddress)): Handle null addresses. From-SVN: r32339
2000-02-26Minor clean up and bug fix.Anthony Green1-1/+1
From-SVN: r32196
2000-02-25re GNATS libgcj/38 (Static initializer in DecimalFormat eventually depends ↵Bryce McKinlay1-7/+21
on itself) 2000-02-25 Bryce McKinlay <bryce@albatross.co.nz> * java/net/URLConnection.java (initializeDateFormats): New private method. (getHeaderFieldDate): Call initializeDateFormats if required. locale, dateFormat1, dateFormat2, dateFormat3: Don't initialize these. Fix for PR libgcj/38. From-SVN: r32153
2000-02-21Makefile.in: Rebuilt.Anthony Green1-4/+21
* Makefile.in: Rebuilt. * Makefile.am (ordinary_java_source_files): Add gnu/gcj/io/DefaultMimeTypes.java and gnu/gcj/io/MimeTypes.java * scripts/MakeDefaultMimeTypes.java: New file. * scripts/mime.types: New file. * scripts/classes.pl: Moved from top level. * classes.pl: Moved to scripts directory. * java/net/URLConnection.java: Implement guessContentTypeFromName. * gnu/gcj/io/MimeTypes.java: New file. * gnu/gcj/io/DefaultMimeTypes.java: New file. From-SVN: r32086
2000-01-19* All files: Updated copyright to reflect Cygnus purchase.Tom Tromey35-35/+35
From-SVN: r31504
2000-01-04natPlainDatagramSocketImpl.cc (peek): Removed unnecesary comment.Warren Levy1-3/+2
* java/net/natPlainDatagramSocketImpl.cc (peek): Removed unnecesary comment. (receive): Set the sender's address in the DatagramPacket. From-SVN: r31218
1999-12-17Boolean.java (Boolean(String)): Set Value' to false on a null String ↵Bryce McKinlay2-60/+29
constructor parameter. 1999-12-16 Bryce McKinlay <bryce@albatross.co.nz> * java/lang/Boolean.java (Boolean(String)): Set Value' to false on a null String constructor parameter. * java/net/natPlainSocketImpl.cc: Remove unneccessary sprintf calls for exception messages. BooleanClass: declare. (setOption): Use BooleanClass instead of Class.forName() for instanceof test. (bind): Cast 4th parameter of setsockopt to char *' for compatibility with older Solaris headers. * java/net/natPlainDatagramSocketImpl.cc: Remove unneccessary sprintf calls for exception messages. BooleanClass, IntegerClass: declare. (setOption): Use BooleanClass and IntegerClass, not Class.forName() for instanceof test. From-SVN: r30988
1999-12-02ServerSocket.java (ServerSocket): Bind to any interface if bindAddr is null.Bryce McKinlay1-1/+1
1999-12-02 Bryce McKinlay <bryce@albatross.co.nz> * libjava/java/net/ServerSocket.java (ServerSocket): Bind to any interface if bindAddr is null. From-SVN: r30755
1999-11-23re GNATS java.net/57 (potential buffer overruns)Bryce McKinlay2-34/+38
1999-11-23 Bryce McKinlay <bryce@albatross.co.nz> * java/net/natPlainSocketImpl.cc: Fix potential buffer overruns in Exception messages. PR java.net/57. (bind): set SO_REUSEADDR before bind. * java/net/natPlainDatagramSocketImpl.cc: Fix potential buffer overruns. PR java.net/57. From-SVN: r30637
1999-10-04natPlainSocketImpl.cc: Don't include headers if java.net is disabled.Tom Tromey1-0/+2
* java/net/natPlainSocketImpl.cc: Don't include headers if java.net is disabled. From-SVN: r29812
1999-10-02configure: Rebuilt.Tom Tromey3-2/+141
* configure: Rebuilt. * configure.in: Set classpath when invoking gcj. Use changequote around sed invocation. * java/net/natPlainSocketImpl.cc: Stub native functions if DISABLE_JAVA_NET is defined. * java/net/natPlainDatagramSocketImpl.cc (setTimeToLive): Fixed typo in exception string. (getTimeToLive): Likewise. Stub native functions if DISABLE_JAVA_NET is defined. * java/net/natInetAddress.cc: Stub native functions if DISABLE_JAVA_NET is defined. * configure.host: Disable java.net for mips-tx39. * configure, include/config.h.in: Rebuilt. * acconfig.h (DISABLE_JAVA_NET): Undefine. * configure.in: Added --disable-java-net and new define `DISABLE_JAVA_NET'. From-SVN: r29759
1999-09-30* java/net/natPlainDatagramSocketImpl.cc: Indentation fix.Tom Tromey1-3/+3
From-SVN: r29737
1999-09-10configure: Rebuilt.Tom Tromey3-4/+4
* configure: Rebuilt. * configure.in: Build include/Makefile. * Makefile.in: Rebuilt. * Makefile.am (SUBDIRS): Added gcj and include. (install-data-local): New target. (extra_headers): New macro. * include/Makefile.in: New file. * include/Makefile.am: New file. * interpret.cc: Don't include gcj/field.h or gcj/cni.h. * java/lang/reflect/natField.cc: Don't include gcj/field.h or gcj/cni.h. * boehm.cc: Don't include java-threads.h or gcj/field.h. * resolve.cc: Include config.h. * defineclass.cc: Include config.h. * include/java-interp.h: Don't include config.h. * include/jvm.h: Include java-threads.h, Object.h, java-gc.h, cni.h. * gcj/javaprims.h: Regenerated namespace decls. * classes.pl (scan): Don't put `;' after closing brace. * Makefile.in: Rebuilt. * Makefile.am (INCLUDES): Added -I for top_srcdir. * configure.in: Create gcj/Makefile. * gcj/Makefile.in: New file. * gcj/Makefile.am: New file. * java/lang/Object.h: Don't include any other headers. * gcj/array.h: Renamed from include/java-array.h. * gcj/field.h: Renamed from include/java-field.h. * gcj/method.h: Renamed from include/java-method.h. * gcj/cni.h, gcj/javaprims.h: Moved from include/. Updated all files to reflect new include structure. From-SVN: r29278
1999-08-21configure.in: Check for in_addr_t in netinet/in.h too.Alexandre Oliva2-1/+10
* configure.in: Check for in_addr_t in netinet/in.h too. Check for ip_mreq too. * acconfig.h: Define HAVE_IN_ADDR_T instead of in_addr_t. (HAVE_STRUCT_IP_MREQ): Added. * configure, include/config.h.in: Rebuilt. * java/net/natInetAddress.cc (aton): Typedef in_addr_t to jint if needed. * java/net/natPlainDatagramSocketImpl.cc (McastReq, mcastGrp): Disable if ip_mreq is not available. From-SVN: r28798
1999-08-18natClassLoader.cc (_Jv_PrepareCompiledClass): Renamed from ↵Kresten Krab Thorup2-0/+522
_Jv_InternClassStrings. * java/lang/natClassLoader.cc (_Jv_PrepareCompiledClass): Renamed from _Jv_InternClassStrings. * prims.cc (_Jv_RunMain): New function. (JvRunMain): Remove gij-support. * gij.cc (main): Use _Jv_RunMain. * java/util/zip/ZipFile.java: Call readDirectory in constructor. * interpret.cc (PUSHA, PUSHI, PUSHF, PUSHL, PUSHD): Don't store argument in temp variable. (continue1): For all op_x2y insns, use temp variable for intermediate value. Also remove some comments. * java/lang/natClass.cc (newInstance): Call _Jv_InitClass. (forName): Don't call _Jv_InitClass. * java/lang/Class.java (getResource,getResourceAsStream): Implement. * java/util/zip/ZipEntry.java (ZipEntry(ZipEntry)): New construcor. * java/util/jar/JarInputStream.java: New file. * java/util/jar/JarEntry.java: New file. * java/util/jar/JarFile.java: New file. * java/net/URLClassLoader.java: New file. * java/net/JarURLConnection.java: New file. * gnu/gcj/protocol/jar/Handler.java: New file. * gnu/gcj/protocol/jar/Connection.java: New file. * java/security/SecureClassLoader.java: New file. * java/lang/ClassLoader.java (parent): New variable. (ClassLoader (ClassLoader)): new constructor. (findClass): New method. (loadClass): Add default 1.2 implementation. (getSystemResourceAsBytes, getResourceAsBytes): Removed. (readfully): Removed. * gnu/gcj/runtime/VMClassLoader.java: Moved from java/lang. (findSystemClass): New method. (VMClassLoader): Constructor rewritten. (init): New method. All other methods removed. * java/lang/natClassLoader.cc: Change use of java::lang::VMClassLoader to gnu::gcj::runtime::VMClassLoader. (_Jv_InternClassStrings): Use _Jv_ResolvePoolEntry. Also handle class entries. (VMClassLoader::findSystemClass): renamed from findBootClass. * Makefile.am: Add new files. (FirstThread.h, ThreadGroup.h): Add _Jv_Main friend. * Makefile.in: Rebuilt. From-SVN: r28748
1999-08-10[multiple changes]Anthony Green1-0/+2
Mon Aug 9 18:33:38 1999 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE> * Makefile: Rebuilt. * Makefile.am (toolexeclibdir): Add $(MULTISUBDIR) even for native builds. * java/net/natPlainSocketImpl.cc: Include <sys/select.h> only if present. * configure: Rebuilt. * configure.in: Properly align --help output, fix capitalization and punctuation. * acinclude.m4: Likewise. 1999-08-09 Kresten Krab Thorup <krab@gnu.org> * include/javaprims.h (_Jv_word, _Jv_word2): New types. * include/java-interp.h (_Jv_InterpMethodInvocation): Use _Jv_word. (_Jv_callInterpretedMethod): Unused. Remove. (_Jv_InterpMethod::run,run_normal,run_synch_object,run_synch_class): Use ffi_raw. * include/java-cpool.h (_Jv_get, _Jv_put): Remove. (_Jv_{store,load}{Indexes,Int,Float,Long,Double}): Use _Jv_word. * boehm.cc (_Jv_MarkObj): Use _Jv_word. * interpret.cc: use _Jv_word. * defineclass.cc: use_Jv_word. * resolve.cc: Use _Jv_word. (_Jv_ResolvePoolEntry): Return _Jv_word. * java/lang/Class.h (_Jv_Constants): Use _Jv_word for cpool. * java/lang/natClassLoader.cc (_Jv_InternClassStrings): Use _Jv_word. * interpret.cc (gnu::gcj::runtime::MethodInvocation::continue1): Change comment. From-SVN: r28641
1999-08-08[multiple changes]Anthony Green1-1/+1
1999-08-09 Anthony Green <green@cygnus.com> * gij.cc: New file. * include/config.h.in: Rebuilt. * acconfig.h: Add INTERPRETER. * configure: Rebuilt. * Makefile.in: Rebuilt. * Makefile.am (libffi_files): Identify the libffi object files for inclusion in libgcj. (LIBFFIINCS): Define. * interpret.cc (gnu::gcj::runtime::MethodInvocation::continue1): Dummy definition for configurations without an interpreter. * java/net/natPlainSocketImpl.cc (getOption): Disamiguate call to java::lang::Boolean constructor. * include/java-interp.h: Always include java-cpool.h. * java/lang/natClassLoader.cc (getVMClassLoader0): Always return 0 when INTERPRETER not defined. * java/lang/Class.h (finalize): Define. * gnu/gcj/util/path/DirectoryPathEntry.java (getURL): Catch IOException from File.getCanonicalPath. (getStream): Likewise. * NEWS: More news. * THANKS: More thanks. 1999-08-09 Kresten Krab Thorup <krab@gnu.org> * resolve.cc (get_ffi_type_from_signature): Generate uint16 for jchar type. (_Jv_PrepareClass): Allow non-abstract classes to have abstract subclasses. (_Jv_ResolvePoolEntry): Revert subclass check for protected fields and methods. * interpret.cc (continue1/perform_invoke): Don't sign extend uint16 return val. (continue1/lshl,lshr): Push long, not int. (continue1/ulshr): Use UINT64, not long long. * defineclass.cc (handleFieldsEnd): Handle case when all fields are static. * java/lang/natClass.cc (forName): Add call to _Jv_InitClass. * java/lang/FirstThread.java (run): Add top-level exception handler. (run0): Renamed from run. 1999-08-08 Kresten Krab Thorup <krab@gnu.org> * configure.in (--with-interpreter): Added. * include/config.h.in (INTERPRETER): Added. * java/lang/ClassLoader.java: File replaced. * java/lang/VMClassLoader.java: New file. * java/lang/natClassLoader.cc: New file. * gnu/gcj/runtime/MethodInvocation.java: New file. * gnu/gcj/util/path/SearchPath.java: New file. * gnu/gcj/util/path/PathEntry.java: New file. * gnu/gcj/util/path/DirectoryPathEntry.java: New file. * gnu/gcj/util/path/ZipPathEntry.java: New file. * gnu/gcj/util/path/URLPathEntry.java: New file. * gnu/gcj/util/path/CacheEntry.java: New file. * include/java-interp.h: New file. * include/java-cpool.h: New file. * include/java-insns.h: New file. * defineclass.cc: New file. * interpret.cc: New file. * resolve.cc: New file. * java/lang/natClass.cc (loaded_classes, _Jv_RegisterClass, _Jv_RegisterClasses, _Jv_FindClassInCache, _Jv_FindClass, _Jv_NewClass, _Jv_FindArrayClass): Moved to natClassLoader.cc. (finalize): New. (STATE_NOTHING, STATE_RESOLVED, STATE_IN_PROGRESS, STATE_DONE, STATE_ERROR): Moved to java/lang/Class.h and renamed with JV_ prefix. (initializeClass): Use new JV_ prefixed names. Also, call ClassLoader::resolveClass instead of _Jv_ResolveClass. * java/lang/Class.h (JV_STATE_PRELOADING, JV_STATE_LOADING, JV_STATE_LOADED, JV_STATE_COMPILED, JV_STATE_PREPARED, JV_STATE_LINKED): New. (_Jv_WaitForState, _Jv_RegisterInitiatingLoader, _Jv_UnregisterClass, _Jv_InternClassStrings): New friends. (_Jv_IsInterpretedClass, _Jv_InitField, _Jv_LookupDeclaredMethod, _Jv_DetermineVTableIndex, _Jv_ResolvePoolEntry, _Jv_PrepareClass, _Jv_ClassReader, _Jv_InterpClass, _Jv_InterpMethod, _Jv_InterpMethodInvocation): New friends for interpreter. (finalize): New. (CONSTANT_Class, CONSTANT_String, etc.): Moved to include/java-cpool.h and renamed with JV_ prefix. * include/jvm.h (_Jv_makeUtf8Const, _Jv_makeUtf8TypeConst): New decls. (_Jv_UnregisterClass): New decl. * java/lang/natClassLoader.cc (_Jv_FindArrayClass): Added class loader argument. (_Jv_FindClass): Use class loader. * prims.cc (_Jv_makeUtf8Const): New function. (_Jv_NewObjectArray): Change use of _Jv_FindArrayClass. (_Jv_NewPrimArray): Ditto. (_Jv_FindClassFromSignature): Ditto. * java/lang/reflect/natArray.cc (newInstance): Ditto. * java/lang/reflect/natMethod.cc (getType): Ditto. * include/java-field.h (_Jv_Field::isRef): Make robust for non-resolved contexts. * boehm.cc (_Jv_MarkObj): Mark interpreter-related fields. Also, don't mark class->next field. * java/lang/VirtualMachineError.java: Added FIXME note. * configure.in (INTERPSPEC): New spec. * libgcj.spec.in: Added INTERPSPEC. * Makefile.am: Added gcjh friends for java/lang/VMClassLoader and gnu/gcj/runtime/MethodInvocation. (libgcj_la_SOURCES): Added resolve.cc defineclass.cc interpret.cc. (ordinary_java_source_files): Added above mentioned java classes. * configure: Rebuilt. * Makefile.in: Rebuilt. From-SVN: r28597
1999-08-03ServerSocket.java: Define ANY_IF.Bryce McKinlay4-22/+13
* java/net/ServerSocket.java: Define ANY_IF. (ServerSocket (int,int)): Use ANY_IF instead of null to bind to all network interfaces. * java/net/DatagramSocket.java (DatagramSocket): ditto. * java/net/natPlainSocketImpl.cc (bind): Expect 0.0.0' instead of null. * java/net/natPlainDatagramSocketImpl (bind): Expect 0.0.0' instead of null. From-SVN: r28429
1999-08-01configure.in: Check for bstring.h.Alexandre Oliva2-0/+10
1999-08-01 Alexandre Oliva <oliva@dcc.unicamp.br> * configure.in: Check for bstring.h. * configure, include/config.h.in: Rebuilt. * java/net/natPlainDatagramSocketImpl.cc: #include bstring.h. * java/net/natPlainSocketImpl.cc: Likewise. From-SVN: r28378
1999-08-01configure.in: Check for struct hostent_data and need for -D_REENTRANT for ↵Alexandre Oliva1-2/+18
gethostbyname_r... 1999-07-31 Alexandre Oliva <oliva@dcc.unicamp.br> * configure.in: Check for struct hostent_data and need for -D_REENTRANT for gethostbyname_r declaration. * java/net/natInetAddress.cc: Define _REENTRANT if needed. (lookup): Use hostent_data for fixed_buffer. * configure, include/config.h.in: Rebuilt. From-SVN: r28369
1999-07-20DatagramSocket.java (DatagramSocket(int, InetAddress)): Default to using ↵Warren Levy2-4/+29
PlainDatagramSocketImpl. * java/net/DatagramSocket.java (DatagramSocket(int, InetAddress)): Default to using PlainDatagramSocketImpl. * java/net/PlainDatagramSocketImpl.java (close): Catch IOException. From-SVN: r28195
1999-07-05URL.java (equals): Compare strings using String.equals.Anthony Green1-10/+22
* java/net/URL.java (equals): Compare strings using String.equals. * java/net/URL.java (sameFile): Ditto. From-SVN: r27947
1999-07-02configure: Rebuilt.Warren Levy1-4/+31
* configure: Rebuilt. * configure.in: Added inet_ntoa to AC_CHECK_FUNCS. * include/config.h.in: Rebuilt. * java/net/natPlainDatagramSocketImpl.cc: Added header checking. (mcastGrp): Updated FIXME comments. (setOption): Fixed typo. (getOption):Implemented IP_MULTICAST_IF. From-SVN: r27929
1999-07-02PlainDatagramSocketImpl.java (ttl): Removed.Warren Levy2-12/+61
* java/net/PlainDatagramSocketImpl.java (ttl): Removed. * java/net/natPlainDatagramSocketImpl.cc (setTimeToLive): Implemented. (getTimeToLive): Implemented. (setOption): Implemented IP_MULTICAST_IF. From-SVN: r27922
1999-06-23DatagramSocketImpl.java (localPort): Fixed typo to match JDK.Warren Levy2-4/+4
* java/net/DatagramSocketImpl.java (localPort): Fixed typo to match JDK. * java/net/natPlainDatagramSocketImpl.cc (bind): ditto. * java/text/ChoiceFormat.java (nextDouble(double, boolean)): Method is not final per JDK. * java/util/PropertyResourceBundle.java (handleGetObject): Method is public per JDK. * java/util/zip/DataFormatException.java: Class extends Exception. * java/util/zip/Deflater.java (finalize): Method is protected per JDK. * java/util/zip/ZipEntry.java: Class implements ZipConstants. * java/util/zip/ZipInputStream.java: ditto. (closeEntry): Changed method name to match JDK spec. From-SVN: r27717
1999-06-18natInetAddress.cc (lookup): Preserve caller-supplied hostname in returned ↵Bryce McKinlay2-6/+8
InetAddress objects. * java/net/natInetAddress.cc (lookup): Preserve caller-supplied hostname in returned InetAddress objects. (getLocalHostname): Fix typo. * java/net/InetAddress.java (getByName): Set hostname on return object. (getLocalHost): Call lookup directly to ensure that a fully-qualified name is returned. From-SVN: r27587
1999-06-17natPlainSocketImpl.cc (bind): Bind to any/all network interfaces if host==NULL.Bryce McKinlay6-50/+72
* java/net/natPlainSocketImpl.cc (bind): Bind to any/all network interfaces if host==NULL. (accept): Throw message with InterruptedIOException. (getOption): Cache localAddress. * java/net/natPlainDatagramSocketImpl.cc (bind): Don't need 'address' for DatagramSocket. (setTimeToLive): Fix compiler warnings. (getOption): Cache localAddress. * java/net/Socket.java (getLocalAddress): Don't need local InetAddress object. Add FIXME comment about calling checkConnect(). * java/net/ServerSocket.java (ServerSocket(int)): Initialize connection queue to 50 as per JDK 1.2 docs. (ServerSocket(int,int)): Listen on all network interfaces by default, per JDK 1.2 docs. * java/net/PlainDatagramSocketImpl.java: Don't need 'address'. Add localAddress caching. From-SVN: r27559
1999-06-11natInetAddress.cc (aton): Fix typos.Bryce McKinlay1-18/+23
* java/net/natInetAddress.cc (aton): Fix typos. (lookup): Use a bigger buffer size for gethostbyname_r on all versions of glibc. Updated FIXME comment explaining this. Modified while loops to not set herr = ERANGE to work around glibc problems. Use user specified hostname in InetAddress result when available (consistent with JDK). From-SVN: r27484
1999-06-03[multiple changes]Warren Levy2-31/+100
1999-06-02 Warren Levy <warrenl@cygnus.com> * java/net/URL.java (URL(URL,String)): Initialize port to -1. Ignore context if spec is an absolute URL. Fix braindead string comparison. (hashCode): Use JDK 1.2 style algorithm. * java/net/URLStreamHandler.java (parseURL): Reimplement to handle context URL properly. 1999-05-30 Anthony Green <green@cygnus.com> * java/net/URLStreamHandler.java (parseURL): Parse relative URLs correctly. Clean up "/../" and "/./" path fragments. From-SVN: r27334
1999-05-28DatagramSocket.java (laddr): Removed.Warren Levy8-54/+297
* java/net/DatagramSocket.java (laddr): Removed. (DatagramSocket): Removed attempts to get or set laddr if null. (getLocalAddress): Reimplemented per spec. * java/net/MulticastSocket.java (setTimeToLive): Throw exception when ttl is 0. (joinGroup): Throw NullPointerException if any argument is null. (leaveGroup): ditto. * java/net/PlainDatagramSocketImpl.java: Updated comments. * java/net/PlainSocketImpl.java (timeout): Added. (getInputStream): Added FIXME comment on how to support timeouts for TCP. * java/net/ServerSocket.java (ServerSocket): Added FIXME comment. * java/net/Socket.java: Added FIXME comments to identify conflicting specs between the JCL and JDK 1.2 documents. * java/net/natPlainDatagramSocketImpl.cc (bind): Use INADDR_ANY if host is null. Get localport value resolved by kernel if bind lport is 0. (receive): Implemented support for timeouts in UDP. (setOption): Implemented based on natPlainSocketImpl version. (getOption): ditto. * java/net/natPlainSocketImpl.cc (bind): Get localport value resolved by kernel if bind lport is 0. (connect): Get localport value resolved by kernel if bind wasn't done to set localport. (accept): Implemented support for timeouts for ServerSocket. (setOption): Save value for SO_TIMEOUT. (getOption): Return timeout for SO_TIMEOUT. From-SVN: r27230
1999-05-26[multiple changes]Warren Levy12-88/+537
1999-05-26 Bryce McKinlay <bryce@albatross.co.nz> * java/net/DatagramSocket.java (getSoTimeout): Verify class type. * java/net/DatagramSocketImpl.java (getOption): Made abstract. (setOption): Made abstract. * java/net/PlainDatagramSocketImpl.java: Mirror SocketOptions fields to avoid cpp conflicts in native code. * java/net/PlainSocketImpl.java: Mirror SocketOptions fields to avoid cpp conflicts in native code. * java/net/ServerSocket.java (toString): Prepended "ServerSocket". * java/net/Socket.java (getLocalAddress): Implemented. (setTcpNoDelay): Implemented. (getTcpNoDelay): Implemented. (setSoLinger): Implemented. (getSoLinger): Implemented. (getSoTimeout): Verify class type. (setSendBufferSize): Implemented. (getSendBufferSize): Implemented. (setReceiveBufferSize): Implemented. (getReceiveBufferSize): Implemented. (toString): Prepended "Socket". * java/net/SocketImpl.java (toString): Rewritten. (getOption): Made abstract. (setOption): Made abstract. * java/net/natPlainSocketImpl.cc (connect): Set localport properly. (setOption): Implemented. (getOption): Implemented. 1999-05-26 Warren Levy <warrenl@cygnus.com> * java/net/DatagramSocket.java (DatagramSocket): Get local host address when null. Set SO_REUSEADDR for multicasts. (getSoTimeout): Implemented. (setSoTimeout): Implemented. * java/net/DatagramSocketImpl.java: Implement SocketOptions interface. * java/net/MulticastSocket.java (getInterface): Implemented. (setInterface): Implemented. (setTimeToLive): Check for invalid ttl. (joinGroup): Verify multicast address and security. (leaveGroup): Verify multicast address and security. (send): Implemented. * java/net/PlainDatagramSocketImpl.java (timeout): Added. (iface): Added. (ttl): Added. (setOption): Added. (getOption): Added. (mcastGrp): Added. (getTTL): Implemented as non-native. (setTTL): ditto. (join): ditto. (leave): ditto. * java/net/ServerSocket.java (setSoTimeout): Implemented. (getSoTimeout): Implemented. (setSocketFactory): Made synchronized. * java/net/Socket.java (setSoTimeout): Implemented. (getSoTimeout): Implemented. (close): Made synchronized. (setSocketImplFactory): Made synchronized. * java/net/SocketImpl.java: Implement SocketOptions interface. * java/net/natInetAddress.cc: Corrected module name at top of file. * java/net/natPlainDatagramSocketImpl.cc (McastReq): Added union. (bind): Added FIXME. (peek): Implemented. (setTTL): Removed. (getTTL): Removed. (join): Removed. (leave): Removed. (mcastGrp): Added. (setOption): Implemented for SO_REUSEADDR. (getOption): Implemented for SO_REUSEADDR. From-SVN: r27184
1999-05-18Makefile.am (ordinary_java_source_files): Added DatagramPacket.java...Warren Levy7-0/+809
* Makefile.am (ordinary_java_source_files): Added DatagramPacket.java, DatagramSocket.java, DatagramSocketImpl.java, MulticastSocket.java, PlainDatagramSocketImpl.java, and SocketOptions.java. (nat_source_files): Added natPlainDatagramSocketImpl.cc. * Makefile.in: Rebuilt. * java/net/DatagramPacket.java: New file. * java/net/DatagramSocket.java: New file. * java/net/DatagramSocketImpl.java: New file. * java/net/MulticastSocket.java: New file. * java/net/PlainDatagramSocketImpl.java: New file. * java/net/SocketOptions.java: New file. * java/net/natPlainDatagramSocketImpl.cc: New file. From-SVN: r26997
1999-05-12PlainSocketImpl.java: Corrected copyright & header comments.Warren Levy3-4/+19
* java/net/PlainSocketImpl.java: Corrected copyright & header comments. * java/net/SocketImpl.java: Added marker for JDK 1.2 work. * java/net/natPlainSocketImpl.cc (bind): Throw BindException. (connect): Throw ConnectException. From-SVN: r26896
1999-04-23Makefile.am: Added URLDecoder and URLEncoder.Warren Levy4-2/+121
* Makefile.am: Added URLDecoder and URLEncoder. * Makefile.in: Rebuilt. * java/net/ServerSocket.java (setSocketFactory): Renamed from setSocketImplFactory to match spec. * java/net/Socket.java (getSoLinger): Changed return type to match spec. * java/net/URLDecoder.java: New file. * java/net/URLEncoder.java: New file. From-SVN: r26605