Skip to content

Commit

Permalink
doc: fix buf.readInt16LE output
Browse files Browse the repository at this point in the history
Previous example didn't account for the 1 byte offset

PR-URL: #5282
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Roman Reiss <me@silverwind.io>
  • Loading branch information
chinedufn authored and silverwind committed Feb 25, 2016
1 parent ee7754b commit 8b1af2f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion doc/api/buffer.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ const buf = new Buffer([1,-2,3,4]);
buf.readInt16BE();
// returns 510
buf.readInt16LE(1);
// returns -511
// returns 1022
```

### buf.readInt32BE(offset[, noAssert])
Expand Down

0 comments on commit 8b1af2f

Please sign in to comment.