Skip to content

Commit

Permalink
use version 0 of 'protocol'
Browse files Browse the repository at this point in the history
  • Loading branch information
Aliaksey Kandratsenka committed Mar 1, 2011
1 parent 0b76757 commit 40e3dca
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions example.escript
Expand Up @@ -2,7 +2,7 @@
-export([main/1]).

unpack_data(Bin) ->
<<Version:32/native-signed,
<<Version:32/native,
StructSize:32/native,
CPULocalMS:64/native,
CPUIdleMS:64/native,
Expand All @@ -15,7 +15,7 @@ unpack_data(Bin) ->
MemActualUsed:64/native,
MemActualFree:64/native>> = Bin,
StructSize = erlang:size(Bin),
Version = -1,
Version = 0,
[{cpu_local_ms, CPULocalMS},
{cpu_idle_ms, CPUIdleMS},
{swap_total, SwapTotal},
Expand Down
2 changes: 1 addition & 1 deletion sigar_port.c
Expand Up @@ -39,7 +39,7 @@ int main(void)
if (req != 0)
break;
memset(&reply, 0, sizeof(reply));
reply.version = (uint32_t)-1;
reply.version = 0;
reply.struct_size = sizeof(reply);

sigar_mem_get(sigar, &mem);
Expand Down

0 comments on commit 40e3dca

Please sign in to comment.