Skip to content
This repository was archived by the owner on Jul 28, 2023. It is now read-only.
This repository was archived by the owner on Jul 28, 2023. It is now read-only.

Buffer overflow error about socket in NddService received data over 8192 #319

@unadlib

Description

@unadlib

Steps to reproduce

Tell us about your environment:

  • ndb version: 1.1.5
  • Platform / OS version: macOS 10.14.3
  • Node.js version: 12.18.3

What steps will reproduce the problem?

SyntaxError: Unexpected end of JSON input

Please include code that reproduces the issue.

  1. run ndb with a big size cli args(over 8192B)

What is the expected result?

normal execution

What happens instead?

throw error

/usr/local/lib/node_modules/ndb/services/ndd_service.js:21
  throw error;
  ^

SyntaxError: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at Socket.<anonymous> (/usr/local/lib/node_modules/ndb/services/ndd_service.js:104:58)
    at Socket.emit (events.js:315:20)
    at addChunk (_stream_readable.js:295:12)
    at readableAddChunk (_stream_readable.js:271:9)
    at Socket.Readable.push (_stream_readable.js:212:10)
    at Pipe.onStreamRead (internal/stream_base_commons.js:186:23)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions