Skip to content

Commit e831433

Browse files
authored
Add missing <cstring> header (flutter#21069)
Fixes the following compilation errors: ../../flutter/shell/platform/linux/fl_value.cc:267:3: error: use of undeclared identifier 'memcpy' memcpy(self->values, data, sizeof(uint8_t) * data_length); ^ ../../flutter/shell/platform/linux/fl_value.cc:284:3: error: use of undeclared identifier 'memcpy' memcpy(self->values, data, sizeof(int32_t) * data_length); ^ ../../flutter/shell/platform/linux/fl_value.cc:294:3: error: use of undeclared identifier 'memcpy' memcpy(self->values, data, sizeof(int64_t) * data_length); ^ ../../flutter/shell/platform/linux/fl_value.cc:304:3: error: use of undeclared identifier 'memcpy' memcpy(self->values, data, sizeof(double) * data_length); ^ ../../flutter/shell/platform/linux/fl_string_codec.cc:29:28: error: use of undeclared identifier 'strlen' return g_bytes_new(text, strlen(text)); ^ ../../flutter/shell/platform/linux/fl_standard_message_codec.cc:512:23: error: use of undeclared identifier 'strlen' size_t length = strlen(text); ^ Signed-off-by: Damian Wrobel <[email protected]>
1 parent 9a6f09d commit e831433

File tree

3 files changed

+3
-0
lines changed

3 files changed

+3
-0
lines changed

shell/platform/linux/fl_standard_message_codec.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
#include "flutter/shell/platform/linux/fl_standard_message_codec_private.h"
77

88
#include <gmodule.h>
9+
#include <cstring>
910

1011
// See lib/src/services/message_codecs.dart in Flutter source for description of
1112
// encoding.

shell/platform/linux/fl_string_codec.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#include "flutter/shell/platform/linux/public/flutter_linux/fl_string_codec.h"
66

77
#include <gmodule.h>
8+
#include <cstring>
89

910
G_DEFINE_QUARK(fl_string_codec_error_quark, fl_string_codec_error)
1011

shell/platform/linux/fl_value.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
#include "flutter/shell/platform/linux/public/flutter_linux/fl_value.h"
66

77
#include <gmodule.h>
8+
#include <cstring>
89

910
struct _FlValue {
1011
FlValueType type;

0 commit comments

Comments
 (0)