diff options
author | uweigand <uweigand@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-10-21 18:21:00 +0000 |
---|---|---|
committer | uweigand <uweigand@138bc75d-0d04-0410-961f-82ee72b054a4> | 2004-10-21 18:21:00 +0000 |
commit | 17c381ce5b34e251656ffec36b0c909f660050b0 (patch) | |
tree | dcc18947be5c12c097f76186d9f8c216b46570d7 /libjava | |
parent | 52cae7bfd8f8df4aabad75705c4d209587d2ddc3 (diff) | |
download | gcc-17c381ce5b34e251656ffec36b0c909f660050b0.tar.gz |
* gnu/java/nio/channels/natFileChannelPosix.cc
(FileChannelImpl::available): Call FIONREAD ioctl with 'int *'
argument instead of 'long *'.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@89391 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libjava')
-rw-r--r-- | libjava/ChangeLog | 6 | ||||
-rw-r--r-- | libjava/gnu/java/nio/channels/natFileChannelPosix.cc | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/libjava/ChangeLog b/libjava/ChangeLog index 65ae5a1a5f0..3940353f2c7 100644 --- a/libjava/ChangeLog +++ b/libjava/ChangeLog @@ -1,3 +1,9 @@ +2004-10-21 Ulrich Weigand <uweigand@de.ibm.com> + + * gnu/java/nio/channels/natFileChannelPosix.cc + (FileChannelImpl::available): Call FIONREAD ioctl with 'int *' + argument instead of 'long *'. + 2004-10-21 Tom Tromey <tromey@redhat.com> * java/util/ResourceBundle.java (tryBundle): Also ignore diff --git a/libjava/gnu/java/nio/channels/natFileChannelPosix.cc b/libjava/gnu/java/nio/channels/natFileChannelPosix.cc index a2c1c7962b0..edc843b903a 100644 --- a/libjava/gnu/java/nio/channels/natFileChannelPosix.cc +++ b/libjava/gnu/java/nio/channels/natFileChannelPosix.cc @@ -380,7 +380,7 @@ jint FileChannelImpl::available (void) { #if defined (FIONREAD) || defined (HAVE_SELECT) || defined (HAVE_FSTAT) - long num = 0; + int num = 0; int r = 0; bool num_set = false; @@ -423,7 +423,7 @@ FileChannelImpl::available (void) && S_ISREG (sb.st_mode) && (where = lseek (fd, 0, SEEK_CUR)) != (off_t) -1) { - num = (long) (sb.st_size - where); + num = (int) (sb.st_size - where); num_set = true; } } |