pavouk/lgi — pull request #36 by jdesgats (2013-01-05 19:50:39+00:00)
Title: Process abort when setting a record field with a callable

Note: I'm a total noob on GLib so I'm not sure if it is a bug or a misuse and even less if my fix is the most cleaver one !

I was playing with DBus APIs when I experienced process aborts while setting objects vtables. Here is a sample to reproduce the bug:

```lua
lgi = require 'lgi'
Gio = lgi.require 'Gio'

vtable = Gio.DBusInterfaceVTable()
vtable.get_property = function() end
```

This code causes the following:

```
$ lua crash.lua

** (process:19235): CRITICAL **: g_arg_info_get_scope: assertion `info != NULL' failed
**
Lgi:ERROR:marshal.c:758:marshal_2c_callable: assertion failed: (scope == GI_SCOPE_TYPE_ASYNC)
[1] 19235 abort (core dumped) lua crash.lua
```

The provided fix seem to do the work and does not leak memory.