From 09f8067f56814f17dd3235f5df50bf9a98d0e3a7 Mon Sep 17 00:00:00 2001 From: "Andrey Halyavin (halyavin)" Date: Sat, 15 Apr 2006 16:04:54 +0000 Subject: [PATCH] fixed bug with coping file with size divisible by 4Kb. git-svn-id: svn://kolibrios.org@68 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/copy2/trunk/copy2.asm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/programs/copy2/trunk/copy2.asm b/programs/copy2/trunk/copy2.asm index 5b1d21589..e481fffc0 100644 --- a/programs/copy2/trunk/copy2.asm +++ b/programs/copy2/trunk/copy2.asm @@ -185,8 +185,8 @@ copy_file: .ok_memory: ; save number of blocks to source_info - shr ebx,9 ; divide by 512 - inc ebx ; blocks++ + add ebx,511 + shr ebx,9 ; round up to 512 boundary mov [source_info.blocks],ebx ; read the source file mov eax,58