fixed ioapi.c