bug fix and compiles on SBC