VirtualBox

Changeset 68333 in vbox


Ignore:
Timestamp:
Aug 8, 2017 8:39:09 AM (7 years ago)
Author:
vboxsync
Message:

Main/EbmlWriter.cpp: Renaming.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Main/src-client/EbmlWriter.cpp

    r68332 r68333  
    5757    std::stack<EbmlSubElement> m_Elements;
    5858    /** The file's handle. */
    59     RTFILE                     m_File;
     59    RTFILE                     m_hFile;
    6060    /** The file's name (path). */
    6161    Utf8Str                    m_strFile;
     
    6464
    6565    Ebml(void)
    66         : m_File(NIL_RTFILE) { }
     66        : m_hFile(NIL_RTFILE) { }
    6767
    6868    virtual ~Ebml(void) { close(); }
     
    7373    inline int create(const char *a_pszFilename, uint64_t fOpen)
    7474    {
    75         int rc = RTFileOpen(&m_File, a_pszFilename, fOpen);
     75        int rc = RTFileOpen(&m_hFile, a_pszFilename, fOpen);
    7676        if (RT_SUCCESS(rc))
    7777        {
     
    9191    inline uint64_t getFileSize(void)
    9292    {
    93         return RTFileTell(m_File);
     93        return RTFileTell(m_hFile);
    9494    }
    9595
     
    9797    inline const RTFILE &getFile(void)
    9898    {
    99         return m_File;
     99        return m_hFile;
    100100    }
    101101
     
    104104    {
    105105        RTFOFF pcbFree;
    106         int rc = RTFileQueryFsSizes(m_File, NULL, &pcbFree, 0, 0);
     106        int rc = RTFileQueryFsSizes(m_hFile, NULL, &pcbFree, 0, 0);
    107107        return (RT_SUCCESS(rc)? (uint64_t)pcbFree : UINT64_MAX);
    108108    }
     
    118118                   m_Elements.size(), m_Elements.top().classId));
    119119
    120         RTFileClose(m_File);
    121         m_File = NIL_RTFILE;
     120        RTFileClose(m_hFile);
     121        m_hFile = NIL_RTFILE;
    122122
    123123        m_strFile = "";
     
    131131    inline bool isOpen(void)
    132132    {
    133         return RTFileIsValid(m_File);
     133        return RTFileIsValid(m_hFile);
    134134    }
    135135
     
    139139        writeClassId(classId);
    140140        /* store the current file offset. */
    141         m_Elements.push(EbmlSubElement(RTFileTell(m_File), classId));
     141        m_Elements.push(EbmlSubElement(RTFileTell(m_hFile), classId));
    142142        /* Indicates that size of the element
    143143         * is unkown (as according to EBML specs).
     
    161161#endif
    162162
    163         uint64_t uPos = RTFileTell(m_File);
     163        uint64_t uPos = RTFileTell(m_hFile);
    164164        uint64_t uSize = uPos - m_Elements.top().offset - 8;
    165         RTFileSeek(m_File, m_Elements.top().offset, RTFILE_SEEK_BEGIN, NULL);
     165        RTFileSeek(m_hFile, m_Elements.top().offset, RTFILE_SEEK_BEGIN, NULL);
    166166
    167167        /* Make sure that size will be serialized as uint64_t. */
    168168        writeUnsignedInteger(uSize | UINT64_C(0x0100000000000000));
    169         RTFileSeek(m_File, uPos, RTFILE_SEEK_BEGIN, NULL);
     169        RTFileSeek(m_hFile, uPos, RTFILE_SEEK_BEGIN, NULL);
    170170        m_Elements.pop();
    171171        return *this;
     
    230230    inline int write(const void *data, size_t size)
    231231    {
    232         return RTFileWrite(m_File, data, size, NULL);
     232        return RTFileWrite(m_hFile, data, size, NULL);
    233233    }
    234234
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette