You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/NodeJS/Javascript/Servers/OutOfProcess/Http/HttpServer.ts
+5-3
Original file line number
Diff line number
Diff line change
@@ -278,9 +278,11 @@ function demarcateMessageEndings(outputStream: NodeJS.WritableStream) {
278
278
if(typeofvalue==='string'){
279
279
// Node appends a new line character at the end of the message. This facilitates reading of the stream: the process reading it reads messages line by line -
280
280
// characters stay in its buffer until a new line character is received. This means that the null terminating character must appear before the last
281
-
// new line character of the message. This approach is slightly heavy handed in that it removes all whitespace at the end of the message, generally,
282
-
// such whitespace is pointless.
283
-
arguments[0]=value.trimRight()+'\0\n';
281
+
// new line character of the message. This approach is inefficent since it allocates 2 new strings.
282
+
//
283
+
// TODO consider sending '\0\n' as a demarcator after sending value (profile). Also need to check if logging from worker threads might affect
0 commit comments