GNOME Bugzilla – Bug 676203
Async methods don't perform parameter checks
Last modified: 2018-05-22 14:24:54 UTC
Created attachment 214223 [details] Test case demonstrating the issue With normal Vala methods, a sanity check is performed to ensure the parameters are of the expected types. This doesn't seem to be happening in async methods in Vala 0.17.0 I've attached a test case that demonstrates the issue. The test() method will fail with "CRITICAL **: test: assertion `s != NULL' failed" The async version, test_async(), triggers an assertion inside g_utf8_strup() instead. A quick look at the generated C code shows that test() performs a null check, whereas the methods corresponding with test_async() do not. Note that I only used the string type here as an example -- the same issue occurs with any type, including Vala classes.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/vala/issues/299.