🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

crc

Package Overview
Dependencies
Maintainers
1
Versions
30
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crc - npm Package Compare versions

Comparing version

to
1.1.0

12

lib/crc.js

@@ -41,4 +41,12 @@ // Generated by CoffeeScript 1.7.1

CRC.prototype.checksum = function() {
return this.crc ^ this.XOR_MASK;
CRC.prototype.checksum = function(signed) {
var sum;
if (signed == null) {
signed = true;
}
sum = this.crc ^ this.XOR_MASK;
if (signed) {
sum = sum >>> 0;
}
return sum;
};

@@ -45,0 +53,0 @@

4

lib/crc32.js

@@ -26,3 +26,3 @@ // Generated by CoffeeScript 1.7.1

_Class.prototype.pack = function(crc) {
return hex((crc & 0xff000000) >> 24) + hex((crc & 0xff0000) >> 16) + hex((crc & 0xff00) >> 8) + hex(crc & 0xff);
return hex(crc >> 24 & 0xff) + hex(crc >> 16 & 0xff) + hex(crc >> 8 & 0xff) + hex(crc & 0xff);
};

@@ -33,3 +33,3 @@

return function(b) {
return _this.crc = ((_this.crc >> 8) & 0x00ffffff) ^ _this.TABLE[(_this.crc ^ b) & 0xff];
return _this.crc = _this.TABLE[(_this.crc ^ b) & 0xff] ^ (_this.crc >>> 8);
};

@@ -36,0 +36,0 @@ })(this));

{
"name": "crc",
"version": "1.0.0",
"version": "1.1.0",
"description": "CRC JavaScript implementation",

@@ -10,4 +10,4 @@ "keywords": [

"scripts": {
"test": "./node_modules/.bin/mocha test/*.spec.coffee",
"pretest": "./node_modules/.bin/coffee --bare --output ./lib --compile ./src/*.coffee"
"test": "mocha test/*.spec.coffee",
"pretest": "coffee --bare --output ./lib --compile ./src/*.coffee"
},

@@ -14,0 +14,0 @@ "author": {

# crc
[![NPM version](https://badge.fury.io/js/crc.png)](http://badge.fury.io/js/crc)
[![Dependency status](https://david-dm.org/alexgorbatchev/crc.png)](https://david-dm.org/alexgorbatchev/crc)
[![devDependency Status](https://david-dm.org/alexgorbatchev/crc/dev-status.png)](https://david-dm.org/alexgorbatchev/crc#info=devDependencies)
[![Build Status](https://secure.travis-ci.org/alexgorbatchev/crc.png?branch=master)](https://travis-ci.org/alexgorbatchev/crc)
[![NPM version](https://badge.fury.io/js/crc.svg)](http://badge.fury.io/js/crc)
[![Dependency status](https://david-dm.org/alexgorbatchev/node-crc.svg)](https://david-dm.org/alexgorbatchev/node-crc)
[![devDependency Status](https://david-dm.org/alexgorbatchev/node-crc/dev-status.svg)](https://david-dm.org/alexgorbatchev/node-crc#info=devDependencies)
[![Build Status](https://api.travis-ci.org/alexgorbatchev/node-crc.svg?branch=master)](https://travis-ci.org/alexgorbatchev/node-crc)
[![GitTip](http://img.shields.io/gittip/alexgorbatchev.svg)](https://www.gittip.com/alexgorbatchev/)
[![NPM](https://nodei.co/npm/crc.png?downloads=true)](https://npmjs.org/package/crc)
[![NPM](https://nodei.co/npm/crc.svg)](https://npmjs.org/package/crc)

@@ -33,3 +34,3 @@ Module for calculating Cyclic Redundancy Check (CRC).

$ npm install
$ make test
$ npm test

@@ -36,0 +37,0 @@ ## Usage Example

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet