Minor bug fix for exported C program