File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99- fixed handling of unexpected problems in the Flow with the main process becoming disconnected
1010- fixed `uptime` value in the framework stats
1111- improved auditlogs by adding `files`
12+ - fixed unexpected errors when compressing/decompressing data via WebSocket
1213
1314========================
14150.0.15
Original file line number Diff line number Diff line change @@ -488,7 +488,14 @@ Controller.prototype.parseinflate = function() {
488488 ctrl . inflatechunks = [ ] ;
489489 ctrl . inflatechunkslength = 0 ;
490490 ctrl . inflatelock = true ;
491- ctrl . inflate . write ( buf ) ;
491+
492+ try {
493+ ctrl . inflate . write ( buf ) ;
494+ } catch ( e ) {
495+ // invalid block
496+ self . onerror ( e ) ;
497+ return ;
498+ }
492499
493500 if ( ! buf . $continue )
494501 ctrl . inflate . write ( Buffer . from ( SOCKET_COMPRESS ) ) ;
@@ -575,7 +582,15 @@ Controller.prototype.senddeflate = function() {
575582 ctrl . deflatechunks = [ ] ;
576583 ctrl . deflatechunkslength = 0 ;
577584 ctrl . deflatelock = true ;
578- ctrl . deflate . write ( buf ) ;
585+
586+ try {
587+ ctrl . deflate . write ( buf ) ;
588+ } catch ( e ) {
589+ // invalid block
590+ self . onerror ( e ) ;
591+ return ;
592+ }
593+
579594 ctrl . deflate . flush ( function ( ) {
580595 if ( ctrl . deflatechunks ) {
581596 var data = concat ( ctrl . deflatechunks , ctrl . deflatechunkslength ) ;
You can’t perform that action at this time.
0 commit comments