found and removed bug when calling c-function with array argument