When searching for fonts, thumbnail dispaly mode will crash Blender #62887

Closed
opened 2019-03-24 00:04:51 +01:00 by Colin · 22 comments

System Information
Operating system: Windows 10
Graphics card: NVIDIA GeForce GTX 1060 3GB

Blender Version
Broken: Version 2.80 Beta, Data: 2019-03-23 01:29 Hash: 045a615f9a, Branch: blender2.7 (Mac and Windows)
Worked: Version 2.79b, Date: 2018-03-22 14:10, Hash: f4dc9f968b

In 2.8, when trying to browse in my font folder in the thumbnail display mode, it immediately crashes. I tried this on both my Windows and Mac machines. It will work in 2.79b so I don't believe it's my computer but a bug in the build.

I'm not sure if a .blend file is required but I attached one. To recreate this, select the text, in the Properties tab, select the Object Data panel, in the Font category, try to choose a font for any of the font styles, and when browsing your files, change the display mode to thumbnail. Chances are, it's going to crash.

Text Thumbnail.blend

**System Information** Operating system: Windows 10 Graphics card: NVIDIA GeForce GTX 1060 3GB **Blender Version** Broken: Version 2.80 Beta, Data: 2019-03-23 01:29 Hash: 045a615f9a4c, Branch: blender2.7 (Mac and Windows) Worked: Version 2.79b, Date: 2018-03-22 14:10, Hash: f4dc9f968b In 2.8, when trying to browse in my font folder in the thumbnail display mode, it immediately crashes. I tried this on both my Windows and Mac machines. It will work in 2.79b so I don't believe it's my computer but a bug in the build. I'm not sure if a .blend file is required but I attached one. To recreate this, select the text, in the Properties tab, select the Object Data panel, in the Font category, try to choose a font for any of the font styles, and when browsing your files, change the display mode to thumbnail. Chances are, it's going to crash. [Text Thumbnail.blend](https://archive.blender.org/developer/F6872941/Text_Thumbnail.blend)
Author

Added subscriber: @ColinStein

Added subscriber: @ColinStein

Added subscriber: @mont29

Added subscriber: @mont29

Cannot confirm that here on linux…

Cannot confirm that here on linux…
Member

Added subscribers: @LazyDodo, @JacquesLucke

Added subscribers: @LazyDodo, @JacquesLucke
Member

Also cannot reproduce here on Ubuntu 18.04.

Maybe a windows issue. @LazyDodo

Also cannot reproduce here on Ubuntu 18.04. Maybe a windows issue. @LazyDodo

Added subscribers: @WilliamReynish, @ZedDB

Added subscribers: @WilliamReynish, @ZedDB

I can't reproduce this either (linux).

@WilliamReynish can you reproduce this?

I can't reproduce this either (linux). @WilliamReynish can you reproduce this?
Member

I can't reproduce on windows either, however if i had to guess, I'd go with @ColinStein may have a corrupted font file that freetype chokes on while rendering the preview? Can you narrow the issue down to one specific font file @ColinStein?

I can't reproduce on windows either, however if i had to guess, I'd go with @ColinStein may have a corrupted font file that freetype chokes on while rendering the preview? Can you narrow the issue down to one specific font file @ColinStein?
Author

In #62887#647718, @LazyDodo wrote:
I can't reproduce on windows either, however if i had to guess, I'd go with @ColinStein may have a corrupted font file that freetype chokes on while rendering the preview? Can you narrow the issue down to one specific font file @ColinStein?

Looks like that could be the answer. I took a font and put it in it's own folder and thumbnail display does work. I'm guessing I have a corrupt font in my font folder. Now... How do I do about figuring out which of the 919 fonts is the bad one?!

Well I guess we figured it out. Should I delete this thread or label it to something?

> In #62887#647718, @LazyDodo wrote: > I can't reproduce on windows either, however if i had to guess, I'd go with @ColinStein may have a corrupted font file that freetype chokes on while rendering the preview? Can you narrow the issue down to one specific font file @ColinStein? Looks like that could be the answer. I took a font and put it in it's own folder and thumbnail display does work. I'm guessing I have a corrupt font in my font folder. Now... How do I do about figuring out which of the 919 fonts is the bad one?! Well I guess we figured it out. Should I delete this thread or label it to something?

To make sure that the issue isn't on our end, you could try to hunt down the file that causes this issue and give it to us so we can reproduce.

To make sure that the issue isn't on our end, you could try to hunt down the file that causes this issue and give it to us so we can reproduce.
Member

Even if the issue is on not on our end, i'd rather look into making blender not crash rather than telling the users 'it's your fault for having a corrupt font'

Fastest way to find the misbehaving font? binary search! make 2 font new font folders, copy about 450 of them to the first one, and the rest to the second one, see which one crashes, make 2 new folders, copy half of the crashing folder to each, repeat until you have only a single font left. should be do-able under 10 steps

Even if the issue is on not on our end, i'd rather look into making blender not crash rather than telling the users 'it's your fault for having a corrupt font' Fastest way to find the misbehaving font? binary search! make 2 font new font folders, copy about 450 of them to the first one, and the rest to the second one, see which one crashes, make 2 new folders, copy half of the crashing folder to each, repeat until you have only a single font left. should be do-able under 10 steps
Author

In #62887#647800, @LazyDodo wrote:
Even if the issue is on not on our end, i'd rather look into making blender not crash rather than telling the users 'it's your fault for having a corrupt font'

Fastest way to find the misbehaving font? binary search! make 2 font new font folders, copy about 450 of them to the first one, and the rest to the second one, see which one crashes, make 2 new folders, copy half of the crashing folder to each, repeat until you have only a single font left. should be do-able under 10 steps

Smart idea. So I did that and sure enough, it was in the As so not too much work. Turns out, it's an emjoi font, which obviously makes sense. Now I can't trust my Mac font folder! So if you're anything like me and you work on 2 machines, don't just copy all the Mac fonts to your Windows machine.

"Apple Color Emoji.ttf" Apple Color Emoji.ttf

> In #62887#647800, @LazyDodo wrote: > Even if the issue is on not on our end, i'd rather look into making blender not crash rather than telling the users 'it's your fault for having a corrupt font' > > Fastest way to find the misbehaving font? binary search! make 2 font new font folders, copy about 450 of them to the first one, and the rest to the second one, see which one crashes, make 2 new folders, copy half of the crashing folder to each, repeat until you have only a single font left. should be do-able under 10 steps Smart idea. So I did that and sure enough, it was in the As so not too much work. Turns out, it's an emjoi font, which obviously makes sense. Now I can't trust my Mac font folder! So if you're anything like me and you work on 2 machines, don't just copy all the Mac fonts to your Windows machine. "Apple Color Emoji.ttf" [Apple Color Emoji.ttf](https://archive.blender.org/developer/F6881776/Apple_Color_Emoji.ttf)
Jacques Lucke was assigned by Sebastian Parborg 2019-03-25 18:15:04 +01:00

Ok, this is on our end:

Backtrace:

Thread 28 "blender" received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffd4ffb700 (LWP 25631)]
0x0000555558a941dd in blf_kerning_cache_new (font=0x7fffd2670008)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_glyph.c:96
96				if (FT_Get_Kerning(font->face, g_prev->idx, g->idx, kc->mode, &delta) == 0) {
(gdb) bt
#0  0x0000555558a941dd in blf_kerning_cache_new (font=0x7fffd2670008)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_glyph.c:96
#1  0x0000555558a90da7 in blf_font_ensure_ascii_kerning (font=0x7fffd2670008, kern_mode=0)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:287
#2  0x0000555558a9165e in blf_font_draw_buffer_ex (font=0x7fffd2670008, str=0x55555c2483e8 "AaBbCc", len=6, r_info=0x0, pen_y=0)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:511
#3  0x0000555558a92097 in blf_font_draw_buffer (font=0x7fffd2670008, str=0x55555c2483e8 "AaBbCc", len=6, r_info=0x0)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:636
#4  0x0000555558a961e8 in BLF_thumb_preview (filename=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", draw_str=0x55555db2d5a0 <thumb_str>,
    draw_str_lines=5 '\005', font_color=0x7fffd4ff62e0, font_size=64, buf=0x7fffd261ff88 "\377\377\377", w=256, h=256, channels=4)
    at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_thumbs.c:116
#5  0x000055555863d08b in IMB_thumb_load_font (filename=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", x=256, y=256)
    at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs_font.c:64
#6  0x000055555863b82e in thumb_create_ex (file_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf",
    uri=0x7fffd4ff8740 "file:///tmp/bugs/Apple%20Color%20Emoji.ttf", thumb=0x7fffd4ff7e90 "8779bce0cf0babf4426aa66f5d281070.png", use_hash=true,
    hash=0x7fffd4ff7ec0 "d348439dc375be8ea2d9691277f7d074", blen_group=0x0, blen_id=0x0, size=THB_LARGE, source=THB_SOURCE_FONT, img=0x0)
    at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:370
#7  0x000055555863bde0 in thumb_create_or_fail (file_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf",
    uri=0x7fffd4ff8740 "file:///tmp/bugs/Apple%20Color%20Emoji.ttf", thumb=0x7fffd4ff7e90 "8779bce0cf0babf4426aa66f5d281070.png", use_hash=true,
    hash=0x7fffd4ff7ec0 "d348439dc375be8ea2d9691277f7d074", blen_group=0x0, blen_id=0x0, size=THB_LARGE, source=THB_SOURCE_FONT)
    at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:463
#8  0x000055555863c556 in IMB_thumb_manage (org_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", size=THB_LARGE, source=THB_SOURCE_FONT)
    at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:620
#9  0x00005555572b1b2e in filelist_cache_preview_runf (pool=0x7fffd0c452c8, taskdata=0x7fffe665e108, UNUSED_threadid=5)
    at /home/zed/programmering/blender_master/blender/source/blender/editors/space_file/filelist.c:1116
#10 0x00005555586d1ef0 in task_scheduler_thread_run (thread_p=0x7fffda1efb78)
    at /home/zed/programmering/blender_master/blender/source/blender/blenlib/intern/task.c:439
- 11 0x00007ffff65763c3 in start_thread () from /lib64/libpthread.so.0
- 12 0x00007ffff27123ef in clone () from /lib64/libc.so.

@JacquesLucke feel free to reassign if this is not for you.

Ok, this is on our end: Backtrace: ``` Thread 28 "blender" received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffd4ffb700 (LWP 25631)] 0x0000555558a941dd in blf_kerning_cache_new (font=0x7fffd2670008) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_glyph.c:96 96 if (FT_Get_Kerning(font->face, g_prev->idx, g->idx, kc->mode, &delta) == 0) { (gdb) bt #0 0x0000555558a941dd in blf_kerning_cache_new (font=0x7fffd2670008) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_glyph.c:96 #1 0x0000555558a90da7 in blf_font_ensure_ascii_kerning (font=0x7fffd2670008, kern_mode=0) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:287 #2 0x0000555558a9165e in blf_font_draw_buffer_ex (font=0x7fffd2670008, str=0x55555c2483e8 "AaBbCc", len=6, r_info=0x0, pen_y=0) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:511 #3 0x0000555558a92097 in blf_font_draw_buffer (font=0x7fffd2670008, str=0x55555c2483e8 "AaBbCc", len=6, r_info=0x0) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_font.c:636 #4 0x0000555558a961e8 in BLF_thumb_preview (filename=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", draw_str=0x55555db2d5a0 <thumb_str>, draw_str_lines=5 '\005', font_color=0x7fffd4ff62e0, font_size=64, buf=0x7fffd261ff88 "\377\377\377", w=256, h=256, channels=4) at /home/zed/programmering/blender_master/blender/source/blender/blenfont/intern/blf_thumbs.c:116 #5 0x000055555863d08b in IMB_thumb_load_font (filename=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", x=256, y=256) at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs_font.c:64 #6 0x000055555863b82e in thumb_create_ex (file_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", uri=0x7fffd4ff8740 "file:///tmp/bugs/Apple%20Color%20Emoji.ttf", thumb=0x7fffd4ff7e90 "8779bce0cf0babf4426aa66f5d281070.png", use_hash=true, hash=0x7fffd4ff7ec0 "d348439dc375be8ea2d9691277f7d074", blen_group=0x0, blen_id=0x0, size=THB_LARGE, source=THB_SOURCE_FONT, img=0x0) at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:370 #7 0x000055555863bde0 in thumb_create_or_fail (file_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", uri=0x7fffd4ff8740 "file:///tmp/bugs/Apple%20Color%20Emoji.ttf", thumb=0x7fffd4ff7e90 "8779bce0cf0babf4426aa66f5d281070.png", use_hash=true, hash=0x7fffd4ff7ec0 "d348439dc375be8ea2d9691277f7d074", blen_group=0x0, blen_id=0x0, size=THB_LARGE, source=THB_SOURCE_FONT) at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:463 #8 0x000055555863c556 in IMB_thumb_manage (org_path=0x7fffe665e108 "/tmp/bugs/Apple Color Emoji.ttf", size=THB_LARGE, source=THB_SOURCE_FONT) at /home/zed/programmering/blender_master/blender/source/blender/imbuf/intern/thumbs.c:620 #9 0x00005555572b1b2e in filelist_cache_preview_runf (pool=0x7fffd0c452c8, taskdata=0x7fffe665e108, UNUSED_threadid=5) at /home/zed/programmering/blender_master/blender/source/blender/editors/space_file/filelist.c:1116 #10 0x00005555586d1ef0 in task_scheduler_thread_run (thread_p=0x7fffda1efb78) at /home/zed/programmering/blender_master/blender/source/blender/blenlib/intern/task.c:439 - 11 0x00007ffff65763c3 in start_thread () from /lib64/libpthread.so.0 - 12 0x00007ffff27123ef in clone () from /lib64/libc.so. ``` @JacquesLucke feel free to reassign if this is not for you.
Jacques Lucke was unassigned by Sebastian Parborg 2019-03-25 18:20:16 +01:00
Sebastian Parborg self-assigned this 2019-03-25 18:20:16 +01:00

nvm, I got it. ;) D4590

nvm, I got it. ;) [D4590](https://archive.blender.org/developer/D4590)

Added subscriber: @brecht

Added subscriber: @brecht

@brecht as @LazyDodo pointed out on IRC, we might want to remove the attachment because of copyright reasons.

@brecht as @LazyDodo pointed out on IRC, we might want to remove the attachment because of copyright reasons.
Author

Well this was my first time submitting a crash. Should I delete the font? What is all of that backtrace? What do I need to do next?

Well this was my first time submitting a crash. Should I delete the font? What is all of that backtrace? What do I need to do next?
Member

@ColinStein, you can just wait for a moment, until the patch by @ZedDB is reviewed. Maybe the bug on Blender is fixed in one or two days. Otherwise just get rid of the font if you don't need it.

@ColinStein, you can just wait for a moment, until the patch by @ZedDB is reviewed. Maybe the bug on Blender is fixed in one or two days. Otherwise just get rid of the font if you don't need it.
Author

In #62887#647996, @JacquesLucke wrote:
@ColinStein, you can just wait for a moment, until the patch by @ZedDB is reviewed. Maybe the bug on Blender is fixed in one or two days. Otherwise just get rid of the font if you don't need it.

Oh yea, I don't need the font. I was asking what do I do here? I don't want to clutter these forums if it's a non-issue.

> In #62887#647996, @JacquesLucke wrote: > @ColinStein, you can just wait for a moment, until the patch by @ZedDB is reviewed. Maybe the bug on Blender is fixed in one or two days. Otherwise just get rid of the font if you don't need it. Oh yea, I don't need the font. I was asking what do I do here? I don't want to clutter these forums if it's a non-issue.
Member

You reported a legit bug that is in the process of getting fixed, you can sit back and wait for the fix to land, once it does the next days buildbot will no longer crash on your font file :)

You reported a legit bug that is in the process of getting fixed, you can sit back and wait for the fix to land, once it does the next days buildbot will no longer crash on your font file :)

This issue was referenced by b2656a6ee4

This issue was referenced by b2656a6ee4d554fdd6dcf9cc0d9427d1a8307a10

Changed status from 'Open' to: 'Resolved'

Changed status from 'Open' to: 'Resolved'
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
6 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#62887
No description provided.