Skip to content

Commit

Permalink
don't make_shared inline
Browse files Browse the repository at this point in the history
  • Loading branch information
emkornfield authored and pitrou committed Jul 2, 2019
1 parent 484b3a2 commit 9f59160
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cpp/src/arrow/python/common.cc
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ Status PyBuffer::Init(PyObject* obj) {
}
return Status::OK();
} else {
return Status(StatusCode::Invalid, "Couldn't convert to buffer.",
std::make_shared<PythonErrorDetail>());
auto detail = std::make_shared<PythonErrorDetail>();
return Status(StatusCode::Invalid, "Couldn't convert to buffer.", detail);
}
}

Expand Down Expand Up @@ -149,8 +149,8 @@ Status PassPyError() {
if (PyErr_Occurred()) {
// Do not call PyErr_Clear, the assumption is that someone further
// up the call stack will want to deal with the Python error.
return Status(StatusCode::UnknownError, "Python Error",
std::make_shared<PythonErrorDetail>());
auto detail = std::make_shared<PythonErrorDetail>();
return Status(StatusCode::UnknownError, "Python Error", detail);
}
return Status::OK();
}
Expand Down

0 comments on commit 9f59160

Please sign in to comment.