This commit is contained in:
Igor Pavlov
2005-05-30 00:00:00 +00:00
committed by Kornel Lesiński
parent 8c1b5c7b7e
commit 3c510ba80b
926 changed files with 40559 additions and 23519 deletions

View File

@@ -4,6 +4,7 @@
#include "ZipHeader.h"
#include "ZipItem.h"
#include "../Common/ItemNameUtils.h"
namespace NArchive {
namespace NZip {
@@ -41,17 +42,8 @@ static const char *kUnknownAttributes = "Unknown file attributes";
bool CItem::IsDirectory() const
{
if (!Name.IsEmpty())
{
#ifdef WIN32
LPCSTR prev = CharPrevExA(GetCodePage(), Name, &Name[Name.Length()], 0);
if (*prev == '/')
return true;
#else
if (Name[Name.Length() - 1) == '/')
return true;
#endif
}
if (NItemName::HasTailSlash(Name, GetCodePage()))
return true;
WORD highAttributes = WORD((ExternalAttributes >> 16 ) & 0xFFFF);
switch(MadeByVersion.HostOS)
{
@@ -91,7 +83,7 @@ bool CItem::IsDirectory() const
}
}
UINT32 CItem::GetWinAttributes() const
UInt32 CItem::GetWinAttributes() const
{
DWORD winAttributes;
switch(MadeByVersion.HostOS)