#######################################################################
#
# waitForJobPrinting
#
# Description:
#       Wait for a job to begin printing before returning.
#       A timeout (seconds) must be specified.  If it doesn't start
#       printing within the timeout period, we exit with code 1.
#       Otherwise, we exit with code 0.
#
# Author:
#       Alan Hlava
#
#######################################################################
#set -x

if [ $# -ne 2 ]
then
        echo "usage: waitForJobPrinting <local-jobID> <timeout>"
        exit 1
fi

exec	waitForAttrValue job current-job-state $1 processing $2
#
#    Version      Date     Time    Owner   Comment
# ------------- -------- -------- -------- ----------------------------
# V             04/14/94 07:05:53 hlava    Original version
# V1.2          04/14/94 07:37:30 hlava    Misc improvements
# V1.3          04/15/94 12:57:10 hlava    BL 6 version
# V1.4          06/28/94 16:48:54 nrjbehrs replaced with waitForAttrValue
# V1.5          02/05/95 10:21:08 kok      Update attribute values
