Job array dependency fix

If a job is submitted that is dependent upon a job array in which
the first task of that array is already purged from slurmctld, then
find another element of that array and properly handle the dependency.
Fixed bad variable from patch 7f135dd0cb3f52bc8e919ab20abfb57c86c881f0
qsub wrapper - Include support for NULL env vars
Merge branch 'slurm-14.03'

Conflicts:
	contribs/torque/qsub.pl