Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Danfuzz node 8 #1

Merged
merged 2 commits into from Sep 4, 2012
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 0 additions & 2 deletions .gitignore
@@ -1,4 +1,2 @@
.lock-wscript
.waf*
build build
oidNative.node oidNative.node
8 changes: 8 additions & 0 deletions binding.gyp
@@ -0,0 +1,8 @@
{
'targets': [
{
'target_name': 'oidNative',
'sources': [ 'src/oidNative.cc' ],
}
]
}
4 changes: 2 additions & 2 deletions package.json
@@ -1,6 +1,6 @@
{ {
"name": "oid", "name": "oid",
"version": "0.4.6", "version": "0.5.0",
"keywords": "keywords":
["object", "id", "identity", "hash", "hashcode", "objid", "oid"], ["object", "id", "identity", "hash", "hashcode", "objid", "oid"],
"description": "description":
Expand Down Expand Up @@ -31,7 +31,7 @@
}, },


"scripts": { "scripts": {
"install": "node-waf configure build", "install": "node-gyp configure build; mkdir -p bin; mv build/Release/*.node bin",
"test": "node test/test.js" "test": "node test/test.js"
} }
} }
2 changes: 1 addition & 1 deletion src/oidNative.cc
Expand Up @@ -57,7 +57,7 @@ Handle<Value> NumberIdHash(const Arguments& args) {
hood.doubleValue = num->Value(); hood.doubleValue = num->Value();


int hash = 56081; // A prime number. int hash = 56081; // A prime number.
for (int i = 0; i < sizeof(double); i++) { for (size_t i = 0; i < sizeof(double); i++) {
hash = (hash * 31) + hood.buffer[i]; hash = (hash * 31) + hood.buffer[i];
} }


Expand Down
39 changes: 0 additions & 39 deletions wscript

This file was deleted.