]> git.ipfire.org Git - thirdparty/vala.git/commit
vala: Non-nullable value-type in coalesce expression needs to be copied 6cfa112524d13f878d02149475079e34cd366116
authorJeremy Philippe <jeremy.philippe@gmail.com>
Wed, 8 Jan 2020 12:20:31 +0000 (13:20 +0100)
committerRico Tzschichholz <ricotz@ubuntu.com>
Wed, 8 Jan 2020 14:01:21 +0000 (15:01 +0100)
commit6cfa112524d13f878d02149475079e34cd366116
treebdead6c5f096e01124912145d2c6d4fd1a27bcb6
parent7850210bafcdd81f5b7a36b82766ae73f0fa0610
vala: Non-nullable value-type in coalesce expression needs to be copied

The code generated by the coalesce expression could lead to stale
pointers to the stack if the right-side expression is an immediate value
(such as an integer literal or a struct).

Fixes https://gitlab.gnome.org/GNOME/vala/issues/893
tests/Makefile.am
tests/control-flow/coalesce-right-value.vala [new file with mode: 0644]
vala/valabinaryexpression.vala