From a7f5cdbeb51af9f64f2a12c7706c1adb5ee47f94 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=96=9F=E9=85=8C=20=E9=B5=AC=E5=85=84?= Date: Sun, 3 Apr 2022 07:54:57 +0900 Subject: [PATCH] Minor bug fixes --- net/WebFrame.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/net/WebFrame.js b/net/WebFrame.js index 9f4effc..ab49f83 100644 --- a/net/WebFrame.js +++ b/net/WebFrame.js @@ -1,6 +1,7 @@ "use strict"; const zlib = require( "zlib" ); +const os = require( "os" ) const cl = global.botanLoader; const Dragonfly = global.Dragonfly; @@ -85,7 +86,7 @@ class WebFrame var method = "GET"; if( this.HTTP.request.isPost ) { - this.requestStr = new CondStream( "/tmp/", 2048 ); + this.requestStr = new CondStream( os.tmpdir(), 2048 ); this.HTTP.request.raw.addListener( "data" , ( x ) => _self.requestStr.write( x ) @@ -101,7 +102,7 @@ class WebFrame var url = this.HTTP.request.raw.url; Dragonfly.Info( ( this.HTTP.request.raw.headers[ "x-forwarded-for" ] || this.HTTP.request.remoteAddr ) + " " - + method + ": " + encodeURI( url ) + + method + ": " + url + " - " + this.HTTP.request.raw.headers["user-agent"] , Dragonfly.Visibility.VISIBLE );