diff --git a/bin/localstate.pl b/bin/localstate.pl
index 96ab9e820f4e80255277753d58a69bd46b7051aa..c3e2ac0dc1f190bafc0df91601cf97dd3d73ff15 100755
--- a/bin/localstate.pl
+++ b/bin/localstate.pl
@@ -174,7 +174,7 @@ my  $s      =   IO::Socket::INET->new(
 if ( defined $s )
 {
     $s->recv(my $data, 8);
-    my  $i      =   unpack('N', $data);
+    my  $i      =   unpack('N', $data) || 0;
     if ( $i > 0 )
     {
         # rfc868 offset (seconds from 1900-01-01 to 1970-01-01)