diff -ur recordmydesktop-0.3.8.1/src/rmd_cache_frame.c recordmydesktop/src/rmd_cache_frame.c
--- recordmydesktop-0.3.8.1/src/rmd_cache_frame.c	2008-12-13 17:00:34.000000000 +0100
+++ recordmydesktop/src/rmd_cache_frame.c	2009-10-01 21:27:07.574037837 +0200
@@ -270,7 +270,7 @@
       unsigned int bytes_per_pixel  = pdata->specs.depth >= 24 ? 4 : 2;
       unsigned int pixels_per_frame = pdata->brwin.rrect.width * pdata->brwin.rrect.height;
       
-      total_received_bytes = ((unsigned int)frameno) * bytes_per_pixel * pixels_per_frame;
+      total_received_bytes = ((unsigned long long int)frameno) * bytes_per_pixel * pixels_per_frame;
     }
 
     if(total_received_bytes){
