зеркало из https://github.com/mozilla/gecko-dev.git
46 строки
1.6 KiB
Diff
46 строки
1.6 KiB
Diff
--- a/toolkit/components/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.h
|
|
+++ b/toolkit/components/protobuf/src/google/protobuf/io/zero_copy_stream_impl_lite.h
|
|
@@ -43,16 +43,17 @@
|
|
|
|
#ifndef GOOGLE_PROTOBUF_IO_ZERO_COPY_STREAM_IMPL_LITE_H__
|
|
#define GOOGLE_PROTOBUF_IO_ZERO_COPY_STREAM_IMPL_LITE_H__
|
|
|
|
#include <memory>
|
|
#ifndef _SHARED_PTR_H
|
|
#include <google/protobuf/stubs/shared_ptr.h>
|
|
#endif
|
|
+#include <vector> /* Needed by GCC 4.9 on Android (see Bug 1186561) */
|
|
#include <string>
|
|
#include <iosfwd>
|
|
#include <google/protobuf/io/zero_copy_stream.h>
|
|
#include <google/protobuf/stubs/callback.h>
|
|
#include <google/protobuf/stubs/common.h>
|
|
#include <google/protobuf/stubs/stl_util.h>
|
|
|
|
|
|
diff --git a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
|
|
--- a/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
|
|
+++ b/toolkit/components/protobuf/src/google/protobuf/stubs/atomicops.h
|
|
@@ -84,17 +84,21 @@ typedef int64 Atomic64;
|
|
#else
|
|
typedef intptr_t Atomic64;
|
|
#endif
|
|
#endif
|
|
#endif
|
|
|
|
// Use AtomicWord for a machine-sized pointer. It will use the Atomic32 or
|
|
// Atomic64 routines below, depending on your architecture.
|
|
+#if defined(__OpenBSD__) && !defined(GOOGLE_PROTOBUF_ARCH_64_BIT) /* See Bug 1192556 */
|
|
+typedef Atomic32 AtomicWord;
|
|
+#else
|
|
typedef intptr_t AtomicWord;
|
|
+#endif
|
|
|
|
// Atomically execute:
|
|
// result = *ptr;
|
|
// if (*ptr == old_value)
|
|
// *ptr = new_value;
|
|
// return result;
|
|
//
|
|
// I.e., replace "*ptr" with "new_value" if "*ptr" used to be "old_value".
|