Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
P
poppler
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 613
    • Issues 613
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 40
    • Merge Requests 40
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • poppler
  • poppler
  • Merge Requests
  • !799

Open
Opened Feb 02, 2021 by Michal@misoContributor
  • Report abuse
Report abuse

Fix thread safety of FT_New_Face, FT_New_Memory_Face and FT_Done_Face

  • Overview 0
  • Commits 5
  • Pipelines 4
  • Changes 4

As is stated in https://www.freetype.org/freetype2/docs/reference/ft2-base_interface.html:

"In multi-threaded applications it is easiest to use one FT_Library object per thread. In case this is too cumbersome, a single FT_Library object across threads is possible also, as long as a mutex lock is used around FT_New_Face and FT_Done_Face."

It is not well possible to use FT_Library object per thread because cairo can call _ft_done_face_uncached from any thread so this patch adds proper mutex locking around FT_New_Face, FT_New_Memory_Face and FT_Done_Face. Mutex is defined alongside FT_Library.

Unfortunately this patch depends on !798 because it touches similar regions.

Edited Feb 02, 2021 by Michal
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Reference: poppler/poppler!799
Source branch: thread_safe_new_done_face