Minor bugfixes, improved portability

* Handle EOFs more gracefully
* Now works on ECL!
Get CCL working