Add lock to the philos' state trunk
authorLukas Jiriste <ljiriste@student.42prague.com>
Fri, 22 Mar 2024 08:46:28 +0000 (09:46 +0100)
committerLukas Jiriste <ljiriste@student.42prague.com>
Fri, 22 Mar 2024 08:46:28 +0000 (09:46 +0100)
commit4cb63d2f63ff19360d2373a7b2b13fd1db777ca5
tree7b566c09ea6b2fd4a2911b2459a3488d373128b7
parentcbc420d5e95de053be904b9dba4ff460d4158cd9
Add lock to the philos' state

This should prevent data races between any philo thread
and the main thread checking their status.
philo/check_death.c
philo/init.c
philo/main.c
philo/philo.h
philo/philos.c