[Vala] Can not get dbus obejct ObjectPath propertie ?

Here is a same code :

using DBus ;

int main(){

        DBus.Connection dbus_con =  DBus.Bus.get(DBus.BusType.SYSTEM);
        dynamic DBus.Object nm = dbus_con.get_object
        ObjectPath[unowned] devices_path = nm.GetDevices();
        for (int i = 0 ; i < devices_path.length ; i++ ){
                string path = devices_path[i];
                dynamic DBus.Object device = dbus_con.get_object
                message(device.Interface); //this works fine.
                ObjectPath ip4conf_path = device.Ip4Config ;
        return 0;

got this error:
(process:10987): GLib-GObject-CRITICAL **: g_value_get_string:
assertion `G_VALUE_HOLDS_STRING (value)' failed

I can get the ObjectPath propertie in d-feet via python ,so is this a
bug of vala?

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]