Skip to content

Man page error describing end-of-record callback function cb2 should say csv_parse #22

@chrisinmtown

Description

@chrisinmtown

I think that file csv.3 in describing cb2 should not refer to function csv_init; I believe it should mention function csv_parse. If you agree here's a patch:

diff --git a/csv.3 b/csv.3
index 9469439..7e9b3ba 100644
--- a/csv.3
+++ b/csv.3
@@ -139,7 +139,7 @@ Multiple options can be specified by OR-ing them together.
 .TP
 \fIcb1\fP is a pointer to the callback function that will be called from \fBcsv_parse()\fP after an entire field has been read. \fIcb1\fP will be called with a pointer to the parsed data (which is NOT nul-terminated unless the CSV_APPEND_NULL option is set), the number of bytes in the data, and the pointer that was passed to \fBcsv_parse()\fP.
 .TP
-\fIcb2\fP is a pointer to the callback function that will be called when the end of a record is encountered, it will be called with the character that caused the record to end, cast to an unsigned char, or -1 if called from csv_fini, and the pointer that was passed to \fBcsv_init()\fP.
+\fIcb2\fP is a pointer to the callback function that will be called when the end of a record is encountered, it will be called with the character that caused the record to end, cast to an unsigned char, or -1 if called from csv_fini, and the pointer that was passed to \fBcsv_parse()\fP.
 .TP
 \fIdata\fP is a pointer to user-defined data that will be passed to the callback functions when invoked.
 .TP

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions