Commit 657df8f5 authored by Anjo Vahldiek's avatar Anjo Vahldiek
Browse files

added marshall for rpc

parent 9e8fdc8e
......@@ -690,6 +690,15 @@ operator<<(marshall &m, unsigned long long x)
return m;
}
marshall &
operator<<(marshall &m, unsigned long x)
{
if(sizeof(unsigned long) == sizeof(unsigned int))
return m << (unsigned int) x;
if(sizeof(unsigned long) == sizeof(unsigned long long))
return m << (unsigned long long) x;
}
void
marshall::pack(int x)
{
......@@ -801,6 +810,15 @@ operator>>(unmarshall &u, unsigned long long &x)
return u;
}
unmarshall &
operator>>(unmarshall &u, unsigned long &x)
{
if(sizeof(unsigned long) == sizeof(unsigned int))
return u >> (unsigned int &) x;
if(sizeof(unsigned long) == sizeof(unsigned long long))
return u >> (unsigned long long &) x;
}
unmarshall &
operator>>(unmarshall &u, std::string &s)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment