get_bom should consider the case the file is empty.
This commit is contained in:
parent
7b85efff0c
commit
1c52d17a4d
@ -2160,6 +2160,8 @@ check_bom(int sno, StreamDesc *st)
|
|||||||
int ch;
|
int ch;
|
||||||
|
|
||||||
ch = st->stream_getc(sno);
|
ch = st->stream_getc(sno);
|
||||||
|
if (ch == EOFCHAR)
|
||||||
|
return TRUE;
|
||||||
switch(ch) {
|
switch(ch) {
|
||||||
case 0xFE:
|
case 0xFE:
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user