未验证 提交 5ad87a93 编写于 作者: E Ebrahim Byagowi 提交者: GitHub

Minor, improve file reading failing condition comment

https://bugzilla.gnome.org/show_bug.cgi?id=659212 for more context
上级 2eaba80c
......@@ -577,7 +577,8 @@ hb_blob_create_from_file (const char *file_name)
struct stat st;
if (unlikely (fstat (fd, &st) == -1)) goto fail;
// If the file size is 0 and isn't regular, give up
// If the file size is 0 and is a regular file, give up
// See https://github.com/GNOME/glib/blob/f9faac7/glib/gmappedfile.c#L139-L142
if (unlikely (st.st_size == 0 && S_ISREG (st.st_mode))) goto fail;
file->length = (unsigned long) st.st_size;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册