Skip to content

Commit

Permalink
unzip2: remove defines from header
Browse files Browse the repository at this point in the history
the users of the header do not need to know these details
  • Loading branch information
ulmus-scott authored and linuxdude42 committed Apr 8, 2022
1 parent 1d5a2b4 commit 53d2c2e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
11 changes: 11 additions & 0 deletions mythtv/libs/libmythbase/unzip2.cpp
Expand Up @@ -24,6 +24,17 @@
#include "mythdate.h"
#include "mythlogging.h"

#define ZIP_ATTR_FILE_TYPE_MASK 0xFE000000
#define ZIP_ATTR_FILE_TYPE_SYMLINK 0xA0000000
#define ZIP_ATTR_FILE_TYPE_NORMAL 0x80000000

#define ZIP_ATTR_USER_PERM_MASK 0x01C00000
#define ZIP_ATTR_GROUP_PERM_MASK 0x03800000
#define ZIP_ATTR_OTHER_PERM_MASK 0x00700000
#define ZIP_ATTR_USER_PERM_SHIFT 22
#define ZIP_ATTR_GROUP_PERM_SHIFT 19
#define ZIP_ATTR_OTHER_PERM_SHIFT 16

UnZip::UnZip(QString zipFileName)
: m_zipFileName(std::move(zipFileName))
{
Expand Down
10 changes: 0 additions & 10 deletions mythtv/libs/libmythbase/unzip2.h
Expand Up @@ -34,16 +34,6 @@ class UnZip
// NOLINTNEXTLINE(readability-uppercase-literal-suffix)
static constexpr uint64_t kSTATS_REQUIRED {ZIP_STAT_NAME|ZIP_STAT_INDEX|ZIP_STAT_SIZE|ZIP_STAT_MTIME|ZIP_STAT_ENCRYPTION_METHOD};

#define ZIP_ATTR_FILE_TYPE_MASK 0xFE000000
#define ZIP_ATTR_FILE_TYPE_SYMLINK 0xA0000000
#define ZIP_ATTR_FILE_TYPE_NORMAL 0x80000000
#define ZIP_ATTR_USER_PERM_MASK 0x01C00000
#define ZIP_ATTR_GROUP_PERM_MASK 0x03800000
#define ZIP_ATTR_OTHER_PERM_MASK 0x00700000
#define ZIP_ATTR_USER_PERM_SHIFT 22
#define ZIP_ATTR_GROUP_PERM_SHIFT 19
#define ZIP_ATTR_OTHER_PERM_SHIFT 16

public:
explicit UnZip(QString zipFile);
~UnZip();
Expand Down

0 comments on commit 53d2c2e

Please sign in to comment.