After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 626551 - GValue boxing is leaky
GValue boxing is leaky
Status: RESOLVED DUPLICATE of bug 623543
Product: vala
Classification: Core
Component: Code Generator
0.9.x
Other All
: Normal major
: ---
Assigned To: Vala maintainers
Vala maintainers
Depends on:
Blocks:
 
 
Reported: 2010-08-10 17:35 UTC by carlo.teubner
Modified: 2010-08-25 07:42 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description carlo.teubner 2010-08-10 17:35:03 UTC
void take_value (Value v)
{
}

void main ()
{
	take_value("blabla");
}

This generates the C code:

void _vala_main (void) {
	GValue _tmp1_;
	GValue _tmp0_ = {0};
	take_value ((_tmp1_ = (g_value_init (&_tmp0_, G_TYPE_STRING), g_value_set_string (&_tmp0_, "blabla"), _tmp0_), &_tmp1_));
}

_tmp0_ (or _tmp1_) should be freed here (g_value_unset()).
Comment 1 Evan Nemerson 2010-08-25 07:42:38 UTC

*** This bug has been marked as a duplicate of bug 623543 ***