ACK

Fabio

On 10/7/2014 5:52 PM, Jan Friesse wrote:
> Init script now checks return code of executing corosync command. If it
> fails, ipc_wait section is skipped, resulting in much faster failure of
> init script.
> 
> Signed-off-by: Jan Friesse <[email protected]>
> ---
>  init/corosync.in | 7 ++++---
>  1 file changed, 4 insertions(+), 3 deletions(-)
> 
> diff --git a/init/corosync.in b/init/corosync.in
> index 9b9c66f..c93f971 100755
> --- a/init/corosync.in
> +++ b/init/corosync.in
> @@ -115,12 +115,13 @@ start()
>       else
>               $prog $COROSYNC_OPTIONS > /dev/null 2>&1
>  
> -             if ! wait_for_ipc; then
> +             if [ "$?" != 0 ] || ! wait_for_ipc; then
>                       failure
>                       rtrn=1
> +             else
> +                     touch $LOCK_FILE
> +                     success
>               fi
> -             touch $LOCK_FILE
> -             success
>       fi
>       echo
>  }
> 
_______________________________________________
discuss mailing list
[email protected]
http://lists.corosync.org/mailman/listinfo/discuss

Reply via email to