I have one C function:
int cgroup_change_cgroup_path(const char * path, pid_t pid, const char *const controllers[])
I want to call it in go language by using cgo. How to pass the third parameter as it accepts a C array of string.
I have one C function:
int cgroup_change_cgroup_path(const char * path, pid_t pid, const char *const controllers[])
I want to call it in go language by using cgo. How to pass the third parameter as it accepts a C array of string.
Copyright © 2021 Jogjafile Inc.
You can build the arrays using c helper functions and then use them.
Here is a solution to the same problem:
golangnuts post by John Barham