fix lzw code for clang