Index: trunk/DataCheck/Monitoring/CheckSwiftSchedule.sh
===================================================================
--- trunk/DataCheck/Monitoring/CheckSwiftSchedule.sh	(revision 19499)
+++ trunk/DataCheck/Monitoring/CheckSwiftSchedule.sh	(revision 19519)
@@ -39,8 +39,7 @@
 function getschedule()
 {
-   text=`links -width 300 -ssl.certificates 0 -dump https://www.swift.psu.edu/operations/obsSchedule.php?d=$1 | grep $1'\|was not found' >> $schedulefile `
+   text=$( { links -width 300 -ssl.certificates 0 -dump https://www.swift.psu.edu/operations/obsSchedule.php?d=$1 | grep $1'\|was not found\|Connection' >> $schedulefile ; } 2>&1 )
    #text=`links -width 300 -ssl.certificates 0 -dump https://www.swift.psu.edu/operations/obsSchedule.php?d=$1 | grep $1 >> $schedulefile `
    check1=$?
-   #echo "check "$check1
    if [ "$text" != "" ] || [ $check1 -gt 0 ]
    then
@@ -48,5 +47,5 @@
       printprocesslog "WARN could not get Swift schedule ("$text", return code: "$check1")"
       echo "WARN could not get Swift schedule ("$text", return code: "$check1")"
-      if [ "$text" = "Connection timed out" ]
+      if [ "$text" = "Connection timed out" ] || [ "$text" = "Connection refused" ]
       then
          printprocesslog "WARN could not connect to https://www.swift.psu.edu/operations/obsSchedule.php?d="$1
@@ -125,7 +124,10 @@
    #   1: differences found
    #  >1: error
+   upd=""
    if [ -e $schedulefile2old ]
    then
-      if diff $schedulefile2 $schedulefile2old >/dev/null 
+      diff $schedulefile2 $schedulefile2old >/dev/null
+      checkdiff=$?
+      if [ $checkdiff -eq 0 ]
       then
          printprocesslog "INFO Schedule did not change."
