Make kMaxSendRecvMsgFDs constexpr-accessible in external contexts

Change-Id: I474186f30f38fb61e656315ebcbdc72d6b107d4e
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2259333
Commit-Queue: Eric Astor <epastor@google.com>
Reviewed-by: Mark Mentovai <mark@chromium.org>
This commit is contained in:
Eric Astor 2020-06-23 10:01:22 -04:00 committed by Commit Bot
parent 9520afb599
commit 7409adbff3
2 changed files with 3 additions and 3 deletions

View File

@ -23,6 +23,8 @@
namespace crashpad { namespace crashpad {
constexpr size_t UnixCredentialSocket::kMaxSendRecvMsgFDs;
// static // static
bool UnixCredentialSocket::CreateCredentialSocketpair(ScopedFileHandle* sock1, bool UnixCredentialSocket::CreateCredentialSocketpair(ScopedFileHandle* sock1,
ScopedFileHandle* sock2) { ScopedFileHandle* sock2) {
@ -49,8 +51,6 @@ bool UnixCredentialSocket::CreateCredentialSocketpair(ScopedFileHandle* sock1,
return true; return true;
} }
constexpr size_t UnixCredentialSocket::kMaxSendRecvMsgFDs = 4;
// static // static
int UnixCredentialSocket::SendMsg(int fd, int UnixCredentialSocket::SendMsg(int fd,
const void* buf, const void* buf,

View File

@ -40,7 +40,7 @@ class UnixCredentialSocket {
//! \brief The maximum number of file descriptors that may be sent/received //! \brief The maximum number of file descriptors that may be sent/received
//! with `SendMsg()` or `RecvMsg()`. //! with `SendMsg()` or `RecvMsg()`.
static const size_t kMaxSendRecvMsgFDs; static constexpr size_t kMaxSendRecvMsgFDs = 4;
//! \brief Wraps `sendmsg()` to send a message with file descriptors. //! \brief Wraps `sendmsg()` to send a message with file descriptors.
//! //!