Browse Source

prevent overflow

ceriel 33 years ago
parent
commit
7d0d84f0c7
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lang/cem/libcc.ansi/time/misc.c

+ 1 - 1
lang/cem/libcc.ansi/time/misc.c

@@ -491,7 +491,7 @@ _dstget(register struct tm *timep)
 		if (timep->tm_yday == begindst)
 			dsttranssec = dsts->ds_sec;
 		else	dsttranssec = dste->ds_sec;
-		cursec = ((timep->tm_hour * 60) + timep->tm_min) * 60
+		cursec = ((timep->tm_hour * 60) + timep->tm_min) * 60L
 			    + timep->tm_sec;
 
 		if ((timep->tm_yday == begindst && cursec >= dsttranssec)