From 68df7bf23401d28b96f433e8c7dbfe1119aafc2e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jes=C3=BAs=20Torres?= Date: Wed, 14 Aug 2024 12:16:58 +0000 Subject: [PATCH] fix: problema mostrando std::thread:id Refs: ull-esit-sistemas-operativos/ssoo-apuntes/issues/16 --- src/cap12/threads-factorial.cpp | 1 + src/cap12/threads.cpp | 3 ++- src/cap13/threads-sync-counter.cpp | 1 + src/cap13/threads-sync-factorial.cpp | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/cap12/threads-factorial.cpp b/src/cap12/threads-factorial.cpp index 46e253b..f20ff59 100644 --- a/src/cap12/threads-factorial.cpp +++ b/src/cap12/threads-factorial.cpp @@ -9,6 +9,7 @@ // #include +#include // Requerido para la conversion de std::thread::id #include #include diff --git a/src/cap12/threads.cpp b/src/cap12/threads.cpp index e104cdd..813a919 100644 --- a/src/cap12/threads.cpp +++ b/src/cap12/threads.cpp @@ -6,7 +6,8 @@ // #include -#include +#include // Requerido para la conversion de std::thread::id +#include void thread_function(int thread_id) { diff --git a/src/cap13/threads-sync-counter.cpp b/src/cap13/threads-sync-counter.cpp index 1967e42..063257b 100644 --- a/src/cap13/threads-sync-counter.cpp +++ b/src/cap13/threads-sync-counter.cpp @@ -9,6 +9,7 @@ #include #include +#include // Requerido para la conversion de std::thread::id #include struct increment_counter_thread_args diff --git a/src/cap13/threads-sync-factorial.cpp b/src/cap13/threads-sync-factorial.cpp index 3b0124d..1c14cb1 100644 --- a/src/cap13/threads-sync-factorial.cpp +++ b/src/cap13/threads-sync-factorial.cpp @@ -14,6 +14,7 @@ #include #include #include +#include // Requerido para la conversion de std::thread::id #include #include