Skip to content

Commit 7429812

Browse files
committed
Refs #22284. Fix issue.
Signed-off-by: Miguel Company <[email protected]>
1 parent 649a4f5 commit 7429812

File tree

2 files changed

+0
-12
lines changed

2 files changed

+0
-12
lines changed

include/fastcdr/Cdr.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -689,12 +689,6 @@ class Cdr
689689
Cdr& serialize(
690690
const std::string& string_t)
691691
{
692-
// An empty string is serialized as a 0 length string.
693-
if (string_t.empty())
694-
{
695-
return serialize(static_cast<uint32_t>(0));
696-
}
697-
698692
// Check there are no null characters in the string.
699693
const char* c_str = string_t.c_str();
700694
const auto str_len = strlen(c_str);

include/fastcdr/FastCdr.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -891,12 +891,6 @@ class Cdr_DllAPI FastCdr
891891
FastCdr& serialize(
892892
const std::string& string_t)
893893
{
894-
// An empty string is serialized as a 0 length string.
895-
if (string_t.empty())
896-
{
897-
return serialize(static_cast<uint32_t>(0));
898-
}
899-
900894
// Check there are no null characters in the string.
901895
const char* c_str = string_t.c_str();
902896
const auto str_len = strlen(c_str);

0 commit comments

Comments
 (0)