[dash] Get proper exit code for $(cmd).

Change-Id: I8a6779b5df49463a6b1f542a4c48c1b0a6fb07f1
diff --git a/third_party/uapp/dash/src/jobs.c b/third_party/uapp/dash/src/jobs.c
index ac30225..25c0ffe 100644
--- a/third_party/uapp/dash/src/jobs.c
+++ b/third_party/uapp/dash/src/jobs.c
@@ -1027,6 +1027,9 @@
 		do {
 			status = process_await_termination (sp->pid, false);
 			if (status >= 0) {
+				// Convert status to something that looks
+				// like a wait()-generated status.
+				status = (status & 0xff) << 8;
 				TRACE(("Job %d: changing status of proc %d from 0x%x to 0x%x\n", jobno(jp), pid, sp->status, status));
 				sp->status = status;
 				thisjob = jp;