Parameter iov in mongoc_gridfs_file_writev() should be of type "const mongoc_iovec_t *" to make it possible to write from a constant data location. Pretty much like for writev(2).
At this time, there is no way around it except to discard const-ness forcefully.