Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
scanfile_init: fix mutex locking - fixes #4033
  • Loading branch information
perexg committed Oct 22, 2016
1 parent a54db94 commit c003ff3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/input/mpegts/scanfile.c
Expand Up @@ -906,8 +906,12 @@ scanfile_init ( const char *muxconf_path, int lock )
#endif

if (!initialized) {
if (lock)
pthread_mutex_lock(&global_lock);
memoryinfo_register(&scanfile_memoryinfo);
initialized = 1;
if (lock)
pthread_mutex_lock(&global_lock);
}

scanfile_total_load = 0;
Expand Down

3 comments on commit c003ff3

@ksooo
Copy link
Contributor

@ksooo ksooo commented on c003ff3 Oct 23, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For me, this change leads to 100% lockup of tvh on startup.

@perexg
Copy link
Contributor Author

@perexg perexg commented on c003ff3 Oct 23, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the fix is in 4931c05 . Doing fixes too quickly.

@ksooo
Copy link
Contributor

@ksooo ksooo commented on c003ff3 Oct 23, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

;-) thx

Please sign in to comment.