Created
March 22, 2011 22:18
-
-
Save ynkdir/882208 to your computer and use it in GitHub Desktop.
vim-crash.sh ubuntu 10.10 glibc iconv bug
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ubuntu 10.10 glibc iconv | |
echo 83d9 | xxd -r -p > test.txt | |
vim -c "edit ++enc=cp932 test.txt" | |
# Vim: Caught deadly signal SEGV | |
# Vim: Finished. | |
# Segmentation fault | |
# | |
# vim/src/fileio.c | |
# 1551 while ((iconv(iconv_fd, (void *)&fromp, &from_size, | |
# 1552 &top, &to_size) | |
# 1553 == (size_t)-1 && ICONV_ERRNO != ICONV_EINVAL) | |
# 1554 || from_size > CONV_RESTLEN) | |
# | |
# Result of iconv() is -1, but from_size == 0 (fromp is consumed). | |
# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment