| Index: chrome/common/ipc_message_utils.h
|
| diff --git a/chrome/common/ipc_message_utils.h b/chrome/common/ipc_message_utils.h
|
| index 2ae2ab5cdbd4b244250f3720befd71cc9585c063..f777d06c8728a09c97ce904deffc9496650f9394 100644
|
| --- a/chrome/common/ipc_message_utils.h
|
| +++ b/chrome/common/ipc_message_utils.h
|
| @@ -176,6 +176,27 @@ struct ParamTraits<long> {
|
| }
|
| };
|
|
|
| +#if defined(OS_LINUX)
|
| +// unsigned long is used for serializing X window ids.
|
| +template <>
|
| +struct ParamTraits<unsigned long> {
|
| + typedef unsigned long param_type;
|
| + static void Write(Message* m, const param_type& p) {
|
| + m->WriteLong(p);
|
| + }
|
| + static bool Read(const Message* m, void** iter, param_type* r) {
|
| + long read_output;
|
| + if (!m->ReadLong(iter, &read_output))
|
| + return false;
|
| + *r = static_cast<unsigned long>(read_output);
|
| + return true;
|
| + }
|
| + static void Log(const param_type& p, std::wstring* l) {
|
| + l->append(StringPrintf(L"%ul", p));
|
| + }
|
| +};
|
| +#endif
|
| +
|
| template <>
|
| struct ParamTraits<size_t> {
|
| typedef size_t param_type;
|
|
|