var utsname C.struct_utsname
I'm trying to do string(utsname.sysname), but I'm getting an error
"cannot convert utsname.sysname (type _Ctype_char) to type string".
How can I convert that char to a string in Go?
I understand that in this specific case I can just read /proc/version,
etc, but I'm curious how char can be converted to string.
Any help would be appreciated.
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firstname.lastname@example.org.
For more options, visit https://groups.google.com/groups/opt_out.