73 |
|
/* read message header */ |
74 |
|
n = read(dpd[0], (char *)&msg, sizeof(MSGHEAD)); |
75 |
|
if (n != sizeof(MSGHEAD)) { |
76 |
< |
if (n >= 0) |
76 |
> |
if (n >= 0) { |
77 |
> |
dpout = NULL; |
78 |
|
error(USER, "display process died"); |
79 |
+ |
} |
80 |
|
if (errno != EAGAIN & errno != EINTR) |
81 |
|
goto readerr; |
82 |
|
return(2); /* acceptable failure */ |
109 |
|
error(INTERNAL, "bad DR_ADDSET from display process"); |
110 |
|
disp_result(DS_STARTIMM, 0, NULL); |
111 |
|
bundle_set(BS_ADD, (PACKHEAD *)buf, msg.nbytes/sizeof(PACKHEAD)); |
112 |
+ |
disp_result(DS_ENDIMM, 0, NULL); |
113 |
+ |
disp_check(0); /* hack -- delete usu. follows add */ |
114 |
+ |
break; |
115 |
+ |
case DR_ADJSET: |
116 |
+ |
if (msg.nbytes % sizeof(PACKHEAD)) |
117 |
+ |
error(INTERNAL, "bad DR_ADJSET from display process"); |
118 |
+ |
disp_result(DS_STARTIMM, 0, NULL); |
119 |
+ |
bundle_set(BS_ADJ, (PACKHEAD *)buf, msg.nbytes/sizeof(PACKHEAD)); |
120 |
|
disp_result(DS_ENDIMM, 0, NULL); |
121 |
|
disp_flush(); |
122 |
|
break; |