Files
nzbget/libpar2-0.2-MSVC8.patch

455 lines
10 KiB
Diff
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
diff -urN libpar2-0.2-original/par2.sln libpar2-0.2-modified/par2.sln
--- libpar2-0.2-original/par2.sln 1970-01-01 01:00:00.000000000 +0100
+++ libpar2-0.2-modified/par2.sln 2007-10-31 08:13:25.055723100 +0100
@@ -0,0 +1,20 @@
+
+Microsoft Visual Studio Solution File, Format Version 9.00
+# Visual C++ Express 2005
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "par2", "par2.vcproj", "{B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|Win32 = Debug|Win32
+ Release|Win32 = Release|Win32
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}.Debug|Win32.ActiveCfg = Debug|Win32
+ {B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}.Debug|Win32.Build.0 = Debug|Win32
+ {B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}.Release|Win32.ActiveCfg = Release|Win32
+ {B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}.Release|Win32.Build.0 = Release|Win32
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+EndGlobal
diff -urN libpar2-0.2-original/par2.vcproj libpar2-0.2-modified/par2.vcproj
--- libpar2-0.2-original/par2.vcproj 1970-01-01 01:00:00.000000000 +0100
+++ libpar2-0.2-modified/par2.vcproj 2007-10-31 14:02:31.412999100 +0100
@@ -0,0 +1,380 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<VisualStudioProject
+ ProjectType="Visual C++"
+ Version="8,00"
+ Name="par2"
+ ProjectGUID="{B2EA2B24-5F2E-42B1-91F0-5954880CDC9B}"
+ Keyword="Win32Proj"
+ >
+ <Platforms>
+ <Platform
+ Name="Win32"
+ />
+ </Platforms>
+ <ToolFiles>
+ </ToolFiles>
+ <Configurations>
+ <Configuration
+ Name="Debug|Win32"
+ OutputDirectory="Debug"
+ IntermediateDirectory="Debug"
+ ConfigurationType="4"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ Optimization="0"
+ PreprocessorDefinitions="WIN32;_DEBUG;_LIB;"
+ MinimalRebuild="true"
+ BasicRuntimeChecks="3"
+ RuntimeLibrary="1"
+ UsePrecompiledHeader="0"
+ ProgramDataBaseFileName="$(IntDir)\par2d.pdb"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="true"
+ DebugInformationFormat="4"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ OutputFile="$(OutDir)\$(ProjectName)d.lib"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ <Configuration
+ Name="Release|Win32"
+ OutputDirectory="Release"
+ IntermediateDirectory="Release"
+ ConfigurationType="4"
+ >
+ <Tool
+ Name="VCPreBuildEventTool"
+ />
+ <Tool
+ Name="VCCustomBuildTool"
+ />
+ <Tool
+ Name="VCXMLDataGeneratorTool"
+ />
+ <Tool
+ Name="VCWebServiceProxyGeneratorTool"
+ />
+ <Tool
+ Name="VCMIDLTool"
+ />
+ <Tool
+ Name="VCCLCompilerTool"
+ PreprocessorDefinitions="WIN32;NDEBUG;_LIB;"
+ RuntimeLibrary="0"
+ UsePrecompiledHeader="0"
+ ProgramDataBaseFileName="$(IntDir)\par2.pdb"
+ WarningLevel="3"
+ Detect64BitPortabilityProblems="true"
+ DebugInformationFormat="3"
+ />
+ <Tool
+ Name="VCManagedResourceCompilerTool"
+ />
+ <Tool
+ Name="VCResourceCompilerTool"
+ />
+ <Tool
+ Name="VCPreLinkEventTool"
+ />
+ <Tool
+ Name="VCLibrarianTool"
+ />
+ <Tool
+ Name="VCALinkTool"
+ />
+ <Tool
+ Name="VCXDCMakeTool"
+ />
+ <Tool
+ Name="VCBscMakeTool"
+ />
+ <Tool
+ Name="VCFxCopTool"
+ />
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
+ </Configuration>
+ </Configurations>
+ <References>
+ </References>
+ <Files>
+ <Filter
+ Name="Header Files"
+ Filter="h;hpp;hxx;hm;inl;inc;xsd"
+ UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
+ >
+ <File
+ RelativePath=".\commandline.h"
+ >
+ </File>
+ <File
+ RelativePath=".\config.h"
+ >
+ </File>
+ <File
+ RelativePath=".\crc.h"
+ >
+ </File>
+ <File
+ RelativePath=".\creatorpacket.h"
+ >
+ </File>
+ <File
+ RelativePath=".\criticalpacket.h"
+ >
+ </File>
+ <File
+ RelativePath=".\datablock.h"
+ >
+ </File>
+ <File
+ RelativePath=".\descriptionpacket.h"
+ >
+ </File>
+ <File
+ RelativePath=".\diskfile.h"
+ >
+ </File>
+ <File
+ RelativePath=".\filechecksummer.h"
+ >
+ </File>
+ <File
+ RelativePath=".\galois.h"
+ >
+ </File>
+ <File
+ RelativePath=".\letype.h"
+ >
+ </File>
+ <File
+ RelativePath=".\libpar2.h"
+ >
+ </File>
+ <File
+ RelativePath=".\mainpacket.h"
+ >
+ </File>
+ <File
+ RelativePath=".\md5.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par1fileformat.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par1repairer.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par1repairersourcefile.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2cmdline.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2creator.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2creatorsourcefile.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2fileformat.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2repairer.h"
+ >
+ </File>
+ <File
+ RelativePath=".\par2repairersourcefile.h"
+ >
+ </File>
+ <File
+ RelativePath=".\parheaders.h"
+ >
+ </File>
+ <File
+ RelativePath=".\recoverypacket.h"
+ >
+ </File>
+ <File
+ RelativePath=".\reedsolomon.h"
+ >
+ </File>
+ <File
+ RelativePath=".\verificationhashtable.h"
+ >
+ </File>
+ <File
+ RelativePath=".\verificationpacket.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Resource Files"
+ Filter="rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx"
+ UniqueIdentifier="{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}"
+ >
+ </Filter>
+ <Filter
+ Name="Source Files"
+ Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
+ UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
+ >
+ <File
+ RelativePath=".\commandline.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\crc.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\creatorpacket.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\criticalpacket.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\datablock.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\descriptionpacket.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\diskfile.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\filechecksummer.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\galois.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\libpar2.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\mainpacket.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\md5.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par1fileformat.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par1repairer.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par1repairersourcefile.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2cmdline.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2creator.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2creatorsourcefile.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2fileformat.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2repairer.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\par2repairersourcefile.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\parheaders.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\recoverypacket.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\reedsolomon.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\verificationhashtable.cpp"
+ >
+ </File>
+ <File
+ RelativePath=".\verificationpacket.cpp"
+ >
+ </File>
+ </Filter>
+ </Files>
+ <Globals>
+ </Globals>
+</VisualStudioProject>
diff -urN libpar2-0.2-original/par2cmdline.h libpar2-0.2-modified/par2cmdline.h
--- libpar2-0.2-original/par2cmdline.h 2005-11-25 17:20:00.000000000 +0100
+++ libpar2-0.2-modified/par2cmdline.h 2007-10-31 08:15:00.669883000 +0100
@@ -59,6 +59,13 @@
# define _SIZE_T_DEFINED
#endif
+#ifndef VERSION
+#define VERSION "0.2"
+#endif
+
+#ifndef PACKAGE
+#define PACKAGE "libpar2"
+#endif
#else // WIN32
#ifdef HAVE_CONFIG_H
diff -urN libpar2-0.2-original/par2repairer.cpp libpar2-0.2-modified/par2repairer.cpp
--- libpar2-0.2-original/par2repairer.cpp 2006-01-20 18:25:20.000000000 +0100
+++ libpar2-0.2-modified/par2repairer.cpp 2008-02-13 15:37:59.899314300 +0100
@@ -78,6 +78,7 @@
delete mainpacket;
delete creatorpacket;
+ delete headers;
}
@@ -1261,7 +1262,7 @@
DiskFile::SplitFilename(filename, path, name);
cout << "Target: \"" << name << "\" - missing." << endl;
- sig_done.emit(name, 0, sourcefile->GetVerificationPacket()->BlockCount());
+ sig_done.emit(name, 0, sourcefile && sourcefile->GetVerificationPacket() ? sourcefile->GetVerificationPacket()->BlockCount() : 0);
}
}
@@ -1804,7 +1805,7 @@
}
}
}
- sig_done.emit(name,count,sourcefile->GetVerificationPacket()->BlockCount());
+ sig_done.emit(name,count, sourcefile && sourcefile->GetVerificationPacket() ? sourcefile->GetVerificationPacket()->BlockCount() : 0);
sig_progress.emit(1000.0);
return true;
}