Skip to content

Commit

Permalink
Fixed build
Browse files Browse the repository at this point in the history
  • Loading branch information
Cactus Dynamics committed Jul 27, 2023
1 parent 789efc9 commit dc52ee8
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 5 deletions.
3 changes: 2 additions & 1 deletion examples/logging_example/main.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <cactus_rt/rt.h>

#include <chrono>
#include <iostream>

using cactus_rt::App;
Expand Down Expand Up @@ -63,7 +64,7 @@ int main() {
std::cout << "Testing RT loop for " << time << " seconds.\n";

app.Start();
sleep(time);
std::this_thread::sleep_for(std::chrono::seconds(time));
app.RequestStop();
app.Join();

Expand Down
3 changes: 2 additions & 1 deletion examples/mutex_example/main.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <cactus_rt/rt.h>

#include <chrono>
#include <cmath>
#include <iostream>

Expand Down Expand Up @@ -96,7 +97,7 @@ void ThreadedDemo() {

constexpr unsigned int time = 10;
app.Start();
sleep(time);
std::this_thread::sleep_for(std::chrono::seconds(time));
app.RequestStop();
app.Join();
}
Expand Down
3 changes: 2 additions & 1 deletion examples/simple_deadline_example/main.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <cactus_rt/rt.h>

#include <chrono>
#include <iostream>

using cactus_rt::App;
Expand Down Expand Up @@ -50,7 +51,7 @@ int main() {
std::cout << "Testing RT loop for " << time << " seconds.\n";

app.Start();
sleep(time);
std::this_thread::sleep_for(std::chrono::seconds(time));
app.RequestStop();
app.Join();

Expand Down
3 changes: 2 additions & 1 deletion examples/simple_example/main.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include <cactus_rt/rt.h>

#include <chrono>
#include <iostream>

using cactus_rt::App;
Expand Down Expand Up @@ -49,7 +50,7 @@ int main() {
std::cout << "Testing RT loop for " << time << " seconds.\n";

app.Start();
sleep(time);
std::this_thread::sleep_for(std::chrono::seconds(time));
app.RequestStop();
app.Join();

Expand Down
2 changes: 1 addition & 1 deletion include/cactus_rt/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ struct AppConfig {
quill::Config logger_config;

// Size of heap to reserve in bytes at program startup.
size_t heap_size;
size_t heap_size = 0;
};

/**
Expand Down
2 changes: 2 additions & 0 deletions src/cactus_rt/signal_handler.cc
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "cactus_rt/signal_handler.h"

#include <unistd.h>

#include <cstring>

namespace cactus_rt {
Expand Down

0 comments on commit dc52ee8

Please sign in to comment.