diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-02-14 21:24:22 +0100 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-02-14 21:24:22 +0100 |
| commit | f6a960c09c9593af72ff6da2c3ed501e01a0f429 (patch) | |
| tree | 783c452486c2528fe0df25d76f49d1d4f20c1d47 /common/common.h | |
| parent | adbe9cdb61e5d12299b8872b2ac27a48036bc95d (diff) | |
| download | philosophers-f6a960c09c9593af72ff6da2c3ed501e01a0f429.tar.gz philosophers-f6a960c09c9593af72ff6da2c3ed501e01a0f429.tar.bz2 philosophers-f6a960c09c9593af72ff6da2c3ed501e01a0f429.zip | |
philo one working (with what may be a hack)
Diffstat (limited to 'common/common.h')
| -rw-r--r-- | common/common.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/common/common.h b/common/common.h index e314960..a838750 100644 --- a/common/common.h +++ b/common/common.h @@ -6,7 +6,7 @@ /* By: cacharle <marvin@42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/02/08 22:58:35 by cacharle #+# #+# */ -/* Updated: 2020/02/14 00:35:30 by cacharle ### ########.fr */ +/* Updated: 2020/02/14 20:45:33 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -48,6 +48,9 @@ typedef struct t_time timeout_eat; t_time timeout_sleep; int meal_num; + t_bool all_alive; + pthread_mutex_t mutex_stdout; + pthread_mutex_t mutex_all_alive; } t_philo_args; typedef void (*t_philo_routine)(void *arg); @@ -79,5 +82,6 @@ void h_putchar(char c); void h_putstr(char *s); void *h_calloc(int count, int size); t_time h_timeval_to_time(struct timeval *tp); +t_time h_time_now(void); #endif |
