Making changes in encode.c