Skip to content

Commit a04cd75

Browse files
author
Matt Woodward
committed
Also fix C package tests
1 parent 4686a62 commit a04cd75

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

c/test_package/legacy.cc

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#include <cstdio>
22
#include <iostream>
33

4-
#include <libsbp/cpp/state.h>
4+
#include <libsbp/legacy/cpp/legacy_state.h>
55
#include <libsbp/legacy/cpp/frame_handler.h>
66

77
struct FileBase {
@@ -52,7 +52,7 @@ class FileWriter : public FileBase, public sbp::IWriter {
5252

5353
class MessageHandler : public sbp::AllFrameHandler {
5454
public:
55-
MessageHandler(sbp::State *input_state, sbp::State *output_state) : AllFrameHandler(input_state),
55+
MessageHandler(sbp::LegacyState *input_state, sbp::LegacyState *output_state) : AllFrameHandler(input_state),
5656
output_state_(output_state) {}
5757

5858
void handle_sbp_frame(uint16_t sender_id, uint16_t message_type, uint8_t payload_length, uint8_t *payload,
@@ -64,7 +64,7 @@ class MessageHandler : public sbp::AllFrameHandler {
6464
}
6565

6666
private:
67-
sbp::State *const output_state_;
67+
sbp::LegacyState *const output_state_;
6868
};
6969

7070
int main() {
@@ -81,8 +81,8 @@ int main() {
8181
return EXIT_FAILURE;
8282
}
8383

84-
sbp::State input_state(&input_file, nullptr);
85-
sbp::State output_state(nullptr, &output_file);
84+
sbp::LegacyState input_state(&input_file, nullptr);
85+
sbp::LegacyState output_state(nullptr, &output_file);
8686
MessageHandler message_handler(&input_state, &output_state);
8787

8888
s8 ret = 0;
@@ -107,4 +107,4 @@ int main() {
107107
}
108108

109109
return EXIT_SUCCESS;
110-
}
110+
}

c/test_package/v4.c

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#include <stdio.h>
22
#include <stdlib.h>
33
#include <libsbp/sbp.h>
4-
#include <libsbp/v4/api.h>
54

65
struct Context {
76
FILE *input_file;
@@ -88,4 +87,4 @@ int main() {
8887
fclose(context.output_file);
8988

9089
return exit_code;
91-
}
90+
}

0 commit comments

Comments
 (0)