diff --git a/CImg.h b/CImg.h
index a5496b60b11c9699b406967f39f141fad0d23fe3..1ef09d9071e36b4a453ded1dbb72ca4a1f25b2aa 100644
--- a/CImg.h
+++ b/CImg.h
@@ -59650,6 +59650,7 @@ namespace cimg_library_suffixed {
           if (ptrd + n<=ptrde) { std::memset(ptrd,v,n); ptrd+=n; }
           else { std::memset(ptrd,v,ptrde - ptrd); break; }
         }
+        base_font.get_shared_row(base_font.height()-1).fill(0); // Remove wrong pixels on last line
       }
 
       // Find optimal font cache location to return.