From e6f33b2793234c7305b6574a6838d8a93f5fb622 Mon Sep 17 00:00:00 2001 From: Christopher Jeffrey Date: Mon, 29 Sep 2014 16:49:34 -0700 Subject: [PATCH] make dest output unsigned. --- src/bitcoindjs.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bitcoindjs.cc b/src/bitcoindjs.cc index 372ddcbe..ecce01fa 100644 --- a/src/bitcoindjs.cc +++ b/src/bitcoindjs.cc @@ -1255,10 +1255,10 @@ NAN_METHOD(FillTransaction) { ssData >> tx; // Destination output - int d_output = 0; + unsigned int d_output = 0; if (options->Get(NanNew("output"))->IsNumber()) { d_output = options->Get(NanNew("output"))->IntegerValue(); - if (d_output < 0 || d_output >= tx.vout.size()) { + if (d_output >= tx.vout.size()) { return NanThrowError("Destination output does not exist"); } }