Socket
Socket
Sign inDemoInstall

jsftp

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jsftp - npm Package Compare versions

Comparing version 0.2.7 to 0.2.8

2

jsftp_test.js

@@ -293,3 +293,3 @@ /*

"test get fileList array": function(next) {
">test get fileList array": function(next) {
var ftp = this.ftp;

@@ -296,0 +296,0 @@ var file1 = "testfile.txt";

@@ -46,6 +46,2 @@ /*

buffer = bufs[i];
if (!Buffer.isBuffer(buffer))
buffer = bufs[i] = new Buffer(buffer);
length += buffer.length;

@@ -56,6 +52,4 @@ }

bufs.forEach(function (buf, i) {
buf = bufs[i];
buf.copy(buffer, index, 0, buf.length);
index += buf.length;
delete bufs[i];
});

@@ -376,3 +370,2 @@

var port = (parseInt(match[1], 10) & 255) * 256 + (parseInt(match[2], 10) & 255);
var contents;

@@ -386,16 +379,22 @@ var onConnect = function() {

var pieces = [];
var onData = function(result) {
if (data.mode === "I")
contents = concat([contents || [], result]);
else
contents = [contents, result].join("\n");
pieces.push(result);
};
var onEnd = function(error) {
callback(error, contents);
if (error)
callback(error);
else if (data.mode === "I")
callback(null, concat(pieces));
else
callback(null, pieces.join("\n"));
};
var psvSocket = Net.createConnection(port, self.host);
psvSocket.setEncoding("utf8");
psvSocket.on("connect", onConnect);
if (data.mode !== "I") {
psvSocket.setEncoding("utf8");
}
psvSocket.once("connect", onConnect);
psvSocket.on("data", onData);

@@ -408,3 +407,3 @@ psvSocket.on("end", onEnd);

// operation.
this.raw.type(data.mode || "I", function(err, res) {
this.raw.type(data.mode, function(err, res) {
self.push(["pasv", doPasv]);

@@ -411,0 +410,0 @@ });

{
"name": "jsftp",
"id": "jsftp",
"version": "0.2.7",
"version": "0.2.8",
"description": "A sane FTP client implementation for NodeJS",

@@ -17,3 +17,3 @@ "keywords": [ "ftp", "protocol", "files", "server", "client", "async" ],

"dependencies": {
"gab": ">=0.0.1"
"gab": ">=0.0.2"
},

@@ -20,0 +20,0 @@ "devDependencies": {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc