[Issue 11112] New: Unable to execute shell commands in different threads
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Mon Sep 23 20:54:12 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=11112
Summary: Unable to execute shell commands in different threads
Product: D
Version: D2
Platform: x86_64
OS/Version: Mac OS X
Status: NEW
Severity: blocker
Priority: P2
Component: Phobos
AssignedTo: nobody at puremagic.com
ReportedBy: jm.niehus at gmail.com
--- Comment #0 from Joshua Niehus <jm.niehus at gmail.com> 2013-09-23 20:54:11 PDT ---
The following produces a seg fault:
//---
module test;
import std.stdio
, std.concurrency
, std.process;
void spawnedFunc(Tid tid) {
receive(
(int i) {
"hello?".writeln;
executeShell("ls -a").output.writeln;
}
);
send(tid, true);
}
void main() {
auto tid = spawn(&spawnedFunc, thisTid);
send(tid, 42);
auto wasSuccessful = receiveOnly!(bool);
writeln("Successfully executed shell.");
}
//---
System info:
OSX 10.8.5
intel i7 3.4 GHz
16 GB RAM
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list