Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix incorrect pointer manipulation #4157

Merged
merged 1 commit into from
Oct 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions tests/regression/result.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

#include "result.h"

char const* result_get_error_string(result_t result) {
const char* result_get_error_string(result_t result) {
switch (result_get_error(result)) {
case result_error_ok:
return "okay";
Expand All @@ -25,6 +25,6 @@ char const* result_get_error_string(result_t result) {
case result_error_round_trip_error:
return "round trip error";
default:
return "unknown error - " + result_get_error(result);
return "unknown error";
}
}
2 changes: 1 addition & 1 deletion tests/regression/result.h
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ static result_error_t result_get_error(result_t result) {
return result.internal_error;
}

char const* result_get_error_string(result_t result);
const char* result_get_error_string(result_t result);

static result_data_t result_get_data(result_t result) {
return result.internal_data;
Expand Down