You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/04/28 07:25:34 UTC

[GitHub] [arrow] pitrou commented on a diff in pull request #13019: ARROW-16390: [C++] Dataset initialization could segfault if called simultaneously

pitrou commented on code in PR #13019:
URL: https://github.com/apache/arrow/pull/13019#discussion_r860567713


##########
cpp/src/arrow/dataset/plan.cc:
##########
@@ -21,17 +21,21 @@
 #include "arrow/dataset/file_base.h"
 #include "arrow/dataset/scanner.h"
 
+#include <mutex>
+
 namespace arrow {
 namespace dataset {
 namespace internal {
 
 void Initialize() {
-  static auto registry = compute::default_exec_factory_registry();
-  if (registry) {
-    InitializeScanner(registry);
-    InitializeDatasetWriter(registry);
-    registry = nullptr;

Review Comment:
   Why was there an assignment to null btw?



-- 
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: github-unsubscribe@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org