mirror of
https://github.com/Ylianst/MeshAgent
synced 2025-12-24 12:13:16 +00:00
1. Updated metadata
2. Fixed compiler warning
This commit is contained in:
@@ -52,7 +52,12 @@ function childContainer()
|
||||
this._client.write(h);
|
||||
this._client.write(d);
|
||||
});
|
||||
|
||||
Object.defineProperty(ret, "descriptorMetadata", {
|
||||
set: function (v)
|
||||
{
|
||||
if (this._client) { this._client.descriptorMetadata = v; }
|
||||
}
|
||||
});
|
||||
ret._ipc = require('net').createServer(); ret._ipc.parent = ret;
|
||||
ret._ipc.on('close', function () { console.log('Child Container Process Closed'); });
|
||||
|
||||
@@ -83,6 +88,7 @@ function childContainer()
|
||||
var script = Buffer.from("console.log('CHILD/START');require('child-container').connect('" + ipcInteger + "');").toString('base64');
|
||||
ret._ipc.once('connection', function onConnect(s)
|
||||
{
|
||||
s.descriptorMetadata = 'child-container';
|
||||
this.parent._client = s;
|
||||
this.parent._client._parent = this;
|
||||
var data;
|
||||
@@ -94,11 +100,6 @@ function childContainer()
|
||||
|
||||
data = { command: 'launch', value: { module: this.parent.options.launch.module, method: this.parent.options.launch.method, args: this.parent.options.launch.args } };
|
||||
this.parent.send(data);
|
||||
s.once('close', function ()
|
||||
{
|
||||
console.log('close emitted');
|
||||
require('MeshAgent').SendCommand({ action: 'msg', type: 'console', value: 'close emitted'});
|
||||
});
|
||||
s.on('data', function (c)
|
||||
{
|
||||
var cLen;
|
||||
|
||||
@@ -74,6 +74,7 @@ function messageBox()
|
||||
ret._ipc.master = ret;
|
||||
ret._ipc.on('ready', function ()
|
||||
{
|
||||
this.descriptorMetadata = 'message-box';
|
||||
if (this.master.timeout != null) { this.master._timeout = setTimeout(function (mstr) { mstr._ipc.exit(); }, this.master.timeout * 1000, this.master); }
|
||||
if (this.master.layout == null)
|
||||
{
|
||||
|
||||
@@ -64,6 +64,7 @@ function dispatch(options)
|
||||
this.parent._client._parent = this;
|
||||
this.close();
|
||||
var d, h = Buffer.alloc(4);
|
||||
s.descriptorMetadata = 'win-dispatcher';
|
||||
|
||||
for (var m in this.parent.options.modules)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user