X-Git-Url: http://plrg.eecs.uci.edu/git/?a=blobdiff_plain;f=Robust%2Fsrc%2FRuntime%2Ffile.c;h=c8997a10601eff191ac8571c45fde704a8ad2b3b;hb=e497b0d05da3e13b5365cc477a6b7d792208b7f7;hp=46740b5cdc583afd0d43cc7b119cb771a40d7548;hpb=b124b7bf09a5eed6e272119acba9cfc5a1374b60;p=IRC.git diff --git a/Robust/src/Runtime/file.c b/Robust/src/Runtime/file.c index 46740b5c..c8997a10 100644 --- a/Robust/src/Runtime/file.c +++ b/Robust/src/Runtime/file.c @@ -144,3 +144,17 @@ long long CALL01(___File______nativeLength_____AR_B, struct ArrayObject * ___pat #endif } #endif + +#ifdef D___FileInputStream______nativeAvailable____I +int CALL11(___FileInputStream______nativeAvailable____I, int fd, int fd) { +#ifdef MULTICORE + return 0; +#else + int avail; + int cur=lseek(fd, 0, SEEK_CUR); + int fsize = lseek(fd, 0, SEEK_END); + avail=fsize-cur; + return avail; +#endif +} +#endif