Wifx / gonetworkmanager

Go D-Bus bindings for NetworkManager
Other
96 stars 42 forks source link

Updating ConnectionSettings #15

Closed iamhoodie closed 3 years ago

iamhoodie commented 3 years ago

How do you update ConnectionSettings? I want to be able to update the IPV4 address-data, but I do not see any way of doing it other than recreating the ConnectingSettings Map.

activeDevConn, _ := device.GetPropertyActiveConnection()
conn, _ := activeDevConn.GetPropertyConnection()
settings, _ := conn.GetSettings()
// If I simply write back the config obtained by the GetSettings method, the following error is called when calling conn.Update()
err := conn.Update(settings)
fmt.Println(err.Error())
//ipv6.addresses: can't set property of type 'a(ayuay)' from value of type 'aav'

My guess is we need to call the DbusVariant method? Any ideas?

mullerch commented 3 years ago

Please check #13