<div>Hi All,</div>
<div>&nbsp;</div>
<div>I want to call an xrl method of a process X in the middle of a function defined in some other process Y.</div>
<div>&nbsp;</div>
<div>The callback function defined in Y which&nbsp;processes the values returned&nbsp;by X simply sets a boolean variable VAR to&nbsp;TRUE if the value of XrlError object is OKAY.</div>
<div>&nbsp;</div>
<div>Below is how I called the xrl method of process X in Y, and wait for the callback to return:</div>
<div>&nbsp;</div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; send_request(argument_list);</div>
<div>&nbsp;</div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; while(!VAR)<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; // Do nothing<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }</div>
<div>&nbsp;</div>
<div>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //&nbsp; When VAR becomes true, do something</div>
<div>&nbsp;</div>
<div>where send_request(argument_list) is a local function in Y which calls the&nbsp;xrl method in the client interface of process X till the request has been successfully sent (As expected, it also sends across the name of the callback function in Y).</div>

<div>&nbsp;</div>
<div>VAR is set to TRUE when the callback in Y is called with an argument of XrlError::OKAY.</div>
<div>&nbsp;</div>
<div>However, waiting in a while loop for VAR to become TRUE through the callback in Y even prevents the xrl_method handler in process X&nbsp;from being called. Hence, the while loop above&nbsp;turns into&nbsp;an infinite loop since VAR will never be set to TRUE by the callback in Y.</div>

<div>&nbsp;</div>
<div>What is the&nbsp;proper way other than a while loop like above for waiting for VAR to become true ?</div>
<div>&nbsp;</div>
<div>Thanks,</div>
<div>Selcuk<br></div>