Skip to content

Commit 6f52171

Browse files
author
Jarkko Paso
authored
Bug fix: socket reference count made 16-bit (ARMmbed#2490)
Increased heap size allowed reference count overflow causing memory corruption
1 parent f51669a commit 6f52171

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/Core/include/ns_socket.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ typedef struct socket {
130130
int8_t id; /*!< socket id */
131131
uint8_t flags; /*!< Socket option flags */
132132
int8_t tasklet; /*!< Receiver tasklet */
133-
uint8_t refcount;
133+
uint16_t refcount;
134134
socket_family_t family;
135135
socket_type_t type;
136136
int8_t default_interface_id;

0 commit comments

Comments
 (0)