Skip to content

Conversation

@glistening
Copy link
Contributor

During building jerryscript with arm-gcc-noneeabi 4.9.3,
maybe-uninitialized warning occurred. This patch fixed the warning.

JerryScript-DCO-1.0-Signed-off-by: Sanggyu Lee sg5.lee@samsung.com

During building jerryscript with arm-gcc-noneeabi 4.9.3,
maybe-uninitialized warning occurred. This patch fixed the warning.

JerryScript-DCO-1.0-Signed-off-by: Sanggyu Lee sg5.lee@samsung.com
@glistening
Copy link
Contributor Author

When I build jerrryscript for tizenrt on artik05x, I met the following warning:

/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-core/ecma/operations/ecma-objects.c: In function 'ecma_op_object_put':
/home/brian/iotjs/jerry-tizenrt/jerryscript/jerry-core/ecma/operations/ecma-objects.c:862:20: error: 'property_ref.value_p' may be used uninitialized in this function [-Werror=maybe-uninitialized]
           setter_p = ecma_get_named_accessor_property_setter (property_ref.value_p);

I fixed the warning by explicitly setting NULL for the union variable.
We use gcc-none-eabi 4.9.3.

Copy link
Contributor

@LaszloLango LaszloLango left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Member

@zherczeg zherczeg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

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.

3 participants