fixed bugs in os_sh_free
implemented os_sh_readOpen