guelfey / go.dbus

Native Go bindings for D-Bus
BSD 2-Clause "Simplified" License
124 stars 42 forks source link

Is SendNullByte needed? #28

Closed jessevdk closed 10 years ago

jessevdk commented 10 years ago

I'm trying to use go.dbus on OS X which doesn't support syscall.Ucred. However, I found that SendNullByte is currently not used anywhere. Can it be removed altogether?

guelfey commented 10 years ago

Nice catch. I did some digging and found out that the daemon implementation can be compiled without support for credentials passing via cmsg (falling back to getsockopt with SO_PEERCRED), which is the case on my system, so it isn't actually needed to send the credentials. Nevertheless, I'll leave it in for the time being. I'll look into the Darwin issue later.