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

make comment_exchange string const #119

Merged
merged 1 commit into from
Jan 11, 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 src/core/codestream/ojph_params.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,7 @@ namespace ojph {
////////////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////////
void comment_exchange::set_string(char* str)
void comment_exchange::set_string(const char* str)
{
size_t t = strlen(str);
if (len > 65531)
Expand All @@ -380,7 +380,7 @@ namespace ojph {
}

//////////////////////////////////////////////////////////////////////////
void comment_exchange::set_data(char* data, ui16 len)
void comment_exchange::set_data(const char* data, ui16 len)
{
if (len > 65531)
OJPH_ERROR(0x000500C2,
Expand Down
6 changes: 3 additions & 3 deletions src/core/common/ojph_params.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,12 +176,12 @@ namespace ojph {
public:
comment_exchange() : data(NULL), len(0), Rcom(0) {}
OJPH_EXPORT
void set_string(char* str);
void set_string(const char* str);
OJPH_EXPORT
void set_data(char* data, ui16 len);
void set_data(const char* data, ui16 len);

private:
char* data;
const char* data;
ui16 len;
ui16 Rcom;
};
Expand Down
Loading