A few solutions are available in previous threads:
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Experiment: dealing with a pointer to a string from C | 8 | 2205 | April 1, 2021 | |
| Calling C from Fortran: Passing Vector of Strings from C to Fortran | 6 | 894 | April 26, 2021 | |
| Iso_c_binding: interface to a C function returning a string | 32 | 4569 | February 18, 2025 | |
| Best practices for passing C strings | 19 | 7091 | July 2, 2024 | |
| Filling a fixed-size string in a C-interoperable type | 6 | 192 | November 5, 2025 |