From 9ac9f6ed590effe3112a675ab18ffab3929f7a0d Mon Sep 17 00:00:00 2001 From: guy awsome Date: Tue, 17 Jan 2023 18:10:40 -0500 Subject: [PATCH] fixed copy paste issue in string memory allocation docs --- _docs/tutorials/advanced/handling_type_memory/index.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_docs/tutorials/advanced/handling_type_memory/index.md b/_docs/tutorials/advanced/handling_type_memory/index.md index 6235057b..1c06cc95 100644 --- a/_docs/tutorials/advanced/handling_type_memory/index.md +++ b/_docs/tutorials/advanced/handling_type_memory/index.md @@ -135,7 +135,7 @@ mypackage__msg__MyType mymsg; // Assigning dynamic memory to the frame_id char sequence mymsg.header.frame_id.capacity = 100; -mymsg.header.frame_id.data = (char*) malloc(mymsg.values.capacity * sizeof(char)); +mymsg.header.frame_id.data = (char*) malloc(mymsg.header.frame_id.capacity * sizeof(char)); mymsg.header.frame_id.size = 0; // Assigning value to the frame_id char sequence