Skip to content

Make data processing thread safe#53

Open
mheinzler wants to merge 1 commit intoaziz:masterfrom
mheinzler:thread-safe
Open

Make data processing thread safe#53
mheinzler wants to merge 1 commit intoaziz:masterfrom
mheinzler:thread-safe

Conversation

@mheinzler
Copy link
Copy Markdown

I'm using this plugin to colorize gcc output and sometimes it happens that the color in the output is displaced because new data is being processed at the same time:
grafik

A thread lock on the data fixed that for me.

In some rare cases it can happen that on_data is called from different
threads at the same time which then messes up the calculation of the
regions to color. A thread lock in on_data and on_finished resolves
this.
@jfcherng
Copy link
Copy Markdown
Collaborator

jfcherng commented Aug 23, 2018

Disclaimer: I am not using the on_data mode so I wont test and merge this PR.

I make this disclaimer just because it looks like I am the only active maintainer in the repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants