Any reason why execute() delays?
Dukc
ajieskola at gmail.com
Mon Jul 27 17:33:23 UTC 2020
I know this is probably abusing D, but I wrote this:
```
enum bridgePath = <path to bridge.exe>;
int main(string[] args)
{ import std.process, std.stdio;
auto result = execute(["wine", bridgePath] ~ args[1 .. $]);
result.output.write;
return result.status;
}
```
However, for some strange reason this one adds up to around 3
seconds of delay when invoked, compared to invoking `wine
bridge.exe <args>` directly. If I instead write
```
int main(string[] args)
{ import std.process;
return spawnProcess(["wine", bridgePath] ~ args[1 .. $]).wait;
}
```
the delay disappears. Does anybody know why?
More information about the Digitalmars-d
mailing list