Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Node Buffer update. #1

Merged
merged 1 commit into from

2 participants

@marcosnils

when I tried to install bufferdiff I realised that the C library couldn't compile due to old node Buffer references.

@pkrumins
Owner

Cool!

@pkrumins pkrumins merged commit 4d79feb into pkrumins:master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Jun 13, 2012
  1. @marcosnils

    Updated node buffers

    marcosnils authored
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 2 deletions.
  1. +2 −2 bufferdiff.cc
View
4 bufferdiff.cc
@@ -28,11 +28,11 @@ EqBuf(const Arguments &args)
Buffer *buf1 = ObjectWrap::Unwrap<Buffer>(args[0]->ToObject());
Buffer *buf2 = ObjectWrap::Unwrap<Buffer>(args[1]->ToObject());
- if (buf1->length() != buf2->length())
+ if (Buffer::Length(buf1) != Buffer::Length(buf2))
return scope.Close(False());
return scope.Close(
- Boolean::New(memcmp(buf1->data(), buf2->data(), buf1->length())==0)
+ Boolean::New(memcmp(Buffer::Data(buf1), Buffer::Data(buf2), Buffer::Length(buf1))==0)
);
}
Something went wrong with that request. Please try again.