From a96ba9b9d85c65d557b22b1199080305b78d13d2 Mon Sep 17 00:00:00 2001 From: Niklas Eiling Date: Fri, 9 Aug 2024 09:58:34 +0200 Subject: [PATCH] fix comments in memory, ethercat and rtp Signed-off-by: Niklas Eiling --- lib/memory.cpp | 6 +++--- lib/nodes/ethercat.cpp | 8 ++++---- lib/nodes/rtp.cpp | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/memory.cpp b/lib/memory.cpp index f2fec0e98..e4452405c 100644 --- a/lib/memory.cpp +++ b/lib/memory.cpp @@ -97,12 +97,12 @@ int villas::node::memory::lock(size_t sz) { mallopt(M_TRIM_THRESHOLD, -1); #ifdef _POSIX_MEMLOCK - /* Lock all current and future memory allocations */ + // Lock all current and future memory allocations ret = mlockall(MCL_CURRENT | MCL_FUTURE); if (ret) return -1; -#endif /* _POSIX_MEMLOCK */ -#endif /* __linux__ */ +#endif // _POSIX_MEMLOCK +#endif // __linux__ return 0; } diff --git a/lib/nodes/ethercat.cpp b/lib/nodes/ethercat.cpp index d6dfe4d1f..424ddef23 100644 --- a/lib/nodes/ethercat.cpp +++ b/lib/nodes/ethercat.cpp @@ -372,10 +372,10 @@ int villas::node::ethercat_init(NodeCompat *n) { w->domain_pd = nullptr; w->domain_regs = nullptr; - /* Placement new for C++ objects */ - new (&w->send) std::atomic(); - new (&w->thread) std::thread(); - new (&w->task) Task(); + // Placement new for C++ objects + new (&w->send) std::atomic(); + new (&w->thread) std::thread(); + new (&w->task) Task(); return 0; } diff --git a/lib/nodes/rtp.cpp b/lib/nodes/rtp.cpp index 4e028b853..553841584 100644 --- a/lib/nodes/rtp.cpp +++ b/lib/nodes/rtp.cpp @@ -470,7 +470,7 @@ int villas::node::rtp_type_start(villas::node::SuperNode *sn) { int villas::node::rtp_type_stop() { int ret; - /* Join worker thread */ + // Join worker thread ret = pthread_kill(re_pthread, SIGUSR1); if (ret) throw RuntimeError("Failed to kill thread");