src/partdownloader.cpp

changeset 1065
c8ecddbd99e9
parent 1064
4c7a353cf583
child 1072
9ce9496427f2
--- a/src/partdownloader.cpp	Sat Jan 28 14:13:01 2017 +0200
+++ b/src/partdownloader.cpp	Sat Jan 28 14:14:28 2017 +0200
@@ -106,8 +106,8 @@
 		// Remove the existing extension, if any. It may be we're here over a typo in the .dat extension.
 		int dotPosition = destination.lastIndexOf(".");
 
-		if ((dotPosition != -1) and (dotPosition >= length(destination) - 4))
-			destination.chop(length(destination) - dotPosition);
+		if ((dotPosition != -1) and (dotPosition >= countof(destination) - 4))
+			destination.chop(countof(destination) - dotPosition);
 
 		destination += ".dat";
 	}

mercurial