diff options
| author | Charles E. Rolke <chug@apache.org> | 2011-10-17 20:55:17 +0000 |
|---|---|---|
| committer | Charles E. Rolke <chug@apache.org> | 2011-10-17 20:55:17 +0000 |
| commit | 601342a7aeb37f41f1ef63bd72bac53eb00c401f (patch) | |
| tree | b8f36e6e1b59f02663cbca51cff917bb9403bd47 /cpp/src/qpid/framing/Uuid.cpp | |
| parent | 1f5ded915cd4fdab570f4bc97641df1b9d2091a1 (diff) | |
| download | qpid-python-601342a7aeb37f41f1ef63bd72bac53eb00c401f.tar.gz | |
QPID-2323 Add Uuid to variant
This patch adds a const_cast to the Uuid buffer references.
On Solaris the Uuid library calls take non-const args.
See also r881679 for related Solaris fix-ups.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1185373 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/framing/Uuid.cpp')
| -rw-r--r-- | cpp/src/qpid/framing/Uuid.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/cpp/src/qpid/framing/Uuid.cpp b/cpp/src/qpid/framing/Uuid.cpp index 945c0a4d24..b3d1e2e1e4 100644 --- a/cpp/src/qpid/framing/Uuid.cpp +++ b/cpp/src/qpid/framing/Uuid.cpp @@ -59,7 +59,9 @@ void Uuid::clear() { // Force int 0/!0 to false/true; avoids compile warnings. bool Uuid::isNull() const { - return !!uuid_is_null(data()); + // This const cast is for Solaris which has a + // uuid_is_null that takes a non const argument + return !!uuid_is_null(const_cast<uint8_t*>(data())); } void Uuid::encode(Buffer& buf) const { |
