New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

mailsplit

Package Overview
Dependencies
Maintainers
1
Versions
53
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mailsplit - npm Package Compare versions

Comparing version 1.2.1 to 1.2.2

15

lib/message-splitter.js

@@ -27,3 +27,2 @@ 'use strict';

// process line by line
// find next line ending

@@ -42,5 +41,7 @@ let pos = 0;

groupstart--;
groupend--;
pos--;
if (data.value.length > 1 && data.value[data.value.length - 2] === 0x0D) {
groupstart--;
groupend--;
pos--;

@@ -58,2 +59,3 @@ if (groupstart < 0 && !this.line) {

groupstart--;
groupend--;
pos--;

@@ -68,8 +70,9 @@ data.value = data.value.slice(0, data.value.length - 1);

// find next <LF> or in case of very long lines, split at 1024 bytes
if (chunk[i] === 0x0A || (i - pos > 1024 && chunk[i] !== 0x0D)) {
// line end
if (chunk[i] === 0x0A) { // line end
let start = pos;
pos = ++i;
return this.processLine(chunk.slice(start, i), false, data => {
if (!data) {

@@ -83,3 +86,2 @@ return iterateData();

} else {
if (group.type === 'body' && groupend >= groupstart && group.node.parentNode) {

@@ -89,3 +91,3 @@ // do not include the last line ending for body

groupend--;
if (groupend > groupstart && chunk[groupend - 1] === 0x0D) {
if (groupend >= groupstart && chunk[groupend - 1] === 0x0D) {
groupend--;

@@ -98,3 +100,2 @@ }

// we have a previous data/body chunk to output
if (groupstart !== groupend) {

@@ -137,3 +138,3 @@ group.value = chunk.slice(groupstart, groupend);

pos--;
if (pos > groupstart && chunk[pos - 1] === 0x0D) {
if (pos >= groupstart && chunk[pos - 1] === 0x0D) {
pos--;

@@ -140,0 +141,0 @@ }

{
"name": "mailsplit",
"version": "1.2.1",
"version": "1.2.2",
"description": "Split email messages into an object stream",

@@ -5,0 +5,0 @@ "main": "index.js",

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