[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-users] c-string-list gives segmentation violation
From: |
Evan Hanson |
Subject: |
Re: [Chicken-users] c-string-list gives segmentation violation |
Date: |
Thu, 4 Jan 2018 15:25:24 +1300 |
Hey David,
On 2018-01-04 8:23, David Ireland wrote:
Any suggestions would be appreciated.
You probably want something like this for return-c-string-list instead:
(define return-c-string-list
(foreign-lambda* c-string-list ()
"const char* f[] = { NULL };"
"C_return(f);"))
char** (a pointer to a char pointer) and char* f[] (an array of char
pointers) are different in a way that matters, here.
Cheers,
Evan