sanjibansg commented on a change in pull request #12426:
URL: https://github.com/apache/arrow/pull/12426#discussion_r810858569
##########
File path: cpp/src/arrow/csv/options.cc
##########
@@ -73,6 +73,9 @@ Status ReadOptions::Validate() const {
WriteOptions WriteOptions::Defaults() { return WriteOptions(); }
Status WriteOptions::Validate() const {
+ if (ARROW_PREDICT_FALSE(delimiter == '\n' || delimiter == '\r' || delimiter
== '"')) {
+ return Status::Invalid("WriteOptions: delimiter cannot be \\r or \\n");
Review comment:
Made the change for checking with eol as well.
##########
File path: cpp/src/arrow/csv/options.cc
##########
@@ -73,6 +73,9 @@ Status ReadOptions::Validate() const {
WriteOptions WriteOptions::Defaults() { return WriteOptions(); }
Status WriteOptions::Validate() const {
+ if (ARROW_PREDICT_FALSE(delimiter == '\n' || delimiter == '\r' || delimiter
== '"')) {
+ return Status::Invalid("WriteOptions: delimiter cannot be \\r or \\n");
Review comment:
Made the change for checking with `eol` as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]