Fix and document corner-cases of time checking
diff --git a/library/x509.c b/library/x509.c
index 4214cee..2ba3f98 100644
--- a/library/x509.c
+++ b/library/x509.c
@@ -922,7 +922,7 @@
     mbedtls_x509_time now;
 
     if( x509_get_current_time( &now ) != 0 )
-        return( -1 );
+        return( 1 );
 
     return( x509_check_time( &now, to ) );
 }
@@ -932,7 +932,7 @@
     mbedtls_x509_time now;
 
     if( x509_get_current_time( &now ) != 0 )
-        return( -1 );
+        return( 1 );
 
     return( x509_check_time( from, &now ) );
 }