add int2buf method