"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "CPP/7zip/Archive/GptHandler.cpp" between
p7zip_15.14.1_src_all.tar.gz and p7zip_16.02_src_all.tar.gz

About: p7zip is a command-line file archiver with a high compression ratio (a port of the Windows program 7za.exe).

GptHandler.cpp  (p7zip_15.14.1_src_all):GptHandler.cpp  (p7zip_16.02_src_all)
skipping to change at line 89 skipping to change at line 89
struct CPartType struct CPartType
{ {
UInt32 Id; UInt32 Id;
const char *Ext; const char *Ext;
const char *Type; const char *Type;
}; };
static const CPartType kPartTypes[] = static const CPartType kPartTypes[] =
{ {
// { 0x0, 0, "Unused" }, // { 0x0, 0, "Unused" },
{ 0x21686148, 0, "BIOS Boot" },
{ 0xC12A7328, 0, "EFI System" }, { 0xC12A7328, 0, "EFI System" },
{ 0x024DEE41, 0, "MBR" }, { 0x024DEE41, 0, "MBR" },
{ 0xE3C9E316, 0, "Windows MSR" }, { 0xE3C9E316, 0, "Windows MSR" },
{ 0xEBD0A0A2, 0, "Windows BDP" }, { 0xEBD0A0A2, 0, "Windows BDP" },
{ 0x5808C8AA, 0, "Windows LDM Metadata" }, { 0x5808C8AA, 0, "Windows LDM Metadata" },
{ 0xAF9B60A0, 0, "Windows LDM Data" }, { 0xAF9B60A0, 0, "Windows LDM Data" },
{ 0xDE94BBA4, 0, "Windows Recovery" }, { 0xDE94BBA4, 0, "Windows Recovery" },
// { 0x37AFFC90, 0, "IBM GPFS" }, // { 0x37AFFC90, 0, "IBM GPFS" },
// { 0xE75CAF8F, 0, "Windows Storage Spaces" }, // { 0xE75CAF8F, 0, "Windows Storage Spaces" },
{ 0x83BD6B9D, 0, "FreeBSD Boot" }, { 0x0FC63DAF, 0, "Linux Data" },
{ 0x0657FD6D, 0, "Linux Swap" },
{ 0x83BD6B9D, 0, "FreeBSD Boot" },
{ 0x516E7CB4, 0, "FreeBSD Data" }, { 0x516E7CB4, 0, "FreeBSD Data" },
{ 0x516E7CB5, 0, "FreeBSD Swap" }, { 0x516E7CB5, 0, "FreeBSD Swap" },
{ 0x516E7CB6, "ufs", "FreeBSD UFS" }, { 0x516E7CB6, "ufs", "FreeBSD UFS" },
{ 0x516E7CB8, 0, "FreeBSD Vinum" }, { 0x516E7CB8, 0, "FreeBSD Vinum" },
{ 0x516E7CB8, "zfs", "FreeBSD ZFS" }, { 0x516E7CB8, "zfs", "FreeBSD ZFS" },
{ 0x48465300, "hfsx", "HFS+" }, { 0x48465300, "hfsx", "HFS+" },
}; };
static int FindPartType(const Byte *guid) static int FindPartType(const Byte *guid)
{ {
UInt32 val = Get32(guid); UInt32 val = Get32(guid);
for (unsigned i = 0; i < ARRAY_SIZE(kPartTypes); i++) for (unsigned i = 0; i < ARRAY_SIZE(kPartTypes); i++)
skipping to change at line 335 skipping to change at line 341
case kpidPath: case kpidPath:
{ {
UString s; UString s;
for (unsigned i = 0; i < kNameLen; i++) for (unsigned i = 0; i < kNameLen; i++)
{ {
wchar_t c = (wchar_t)Get16(item.Name + i * 2); wchar_t c = (wchar_t)Get16(item.Name + i * 2);
if (c == 0) if (c == 0)
break; break;
s += c; s += c;
} }
if (s.IsEmpty())
{
char temp[16];
ConvertUInt32ToString(index, temp);
s.AddAscii(temp);
}
{ {
int typeIndex = FindPartType(item.Type); int typeIndex = FindPartType(item.Type);
s += L'.'; s += L'.';
const char *ext = "img"; const char *ext = "img";
if (typeIndex >= 0 && kPartTypes[(unsigned)typeIndex].Ext) if (typeIndex >= 0 && kPartTypes[(unsigned)typeIndex].Ext)
ext = kPartTypes[(unsigned)typeIndex].Ext; ext = kPartTypes[(unsigned)typeIndex].Ext;
s.AddAscii(ext); s.AddAscii(ext);
} }
prop = s; prop = s;
break; break;
 End of changes. 4 change blocks. 
2 lines changed or deleted 14 lines changed or added

Home  |  About  |  All  |  Newest  |  Fossies Dox  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTPS