natString.cc (substring): optimize where substring is entire String.
1999-07-22 Bryce McKinlay <bryce@albatross.co.nz> * java/lang/natString.cc (substring): optimize where substring is entire String. * java/io/File.java (getName): don't return separator with file name. * java/io/natFile.cc (attr): fix overflow. From-SVN: r28246
This commit is contained in:
parent
648d2ffce8
commit
41296e2a23
4 changed files with 11 additions and 4 deletions
|
@ -105,7 +105,7 @@ java::io::File::attr (jstring canon, jint query)
|
|||
JvAssert (query == MODIFIED || query == LENGTH);
|
||||
// FIXME: time computation is very POSIX-specific -- POSIX and Java
|
||||
// have the same Epoch.
|
||||
return query == MODIFIED ? sb.st_mtime * 1000 : sb.st_size;
|
||||
return query == MODIFIED ? (jlong)sb.st_mtime * 1000 : sb.st_size;
|
||||
#else
|
||||
// There's no good choice here.
|
||||
return 23;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue