Skip to content

Memory leak in telebot_get_updates()#46

Merged
smartnode merged 1 commit intosmartnode:masterfrom
nekijbt:patch-1
May 1, 2021
Merged

Memory leak in telebot_get_updates()#46
smartnode merged 1 commit intosmartnode:masterfrom
nekijbt:patch-1

Conversation

@nekijbt
Copy link
Contributor

@nekijbt nekijbt commented Mar 30, 2021

Defining another one internal variable "struct json_object *array" in curly braces makes next call "json_object_put(array)" meaningless, do not free LOST pointer to "array" and cause memory leak.

Declaring another one internal variable "struct json_object *array" in curly braces makes next call "json_object_put(array)" meaningless, not freing LOST pointer to "array" and cause memory leak.
@smartnode
Copy link
Owner

Thanks for the fix.

@smartnode smartnode merged commit 470994b into smartnode:master May 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants