DiscIO: Simplify GetUniqueID in VolumeDirectory
This commit is contained in:
parent
09c1ad1631
commit
b34f2a78f5
|
@ -148,12 +148,8 @@ bool CVolumeDirectory::Read(u64 _Offset, u64 _Length, u8* _pBuffer) const
|
||||||
|
|
||||||
std::string CVolumeDirectory::GetUniqueID() const
|
std::string CVolumeDirectory::GetUniqueID() const
|
||||||
{
|
{
|
||||||
char buffer[7];
|
static const size_t ID_LENGTH = 6;
|
||||||
memcpy(buffer, m_diskHeader.data(), 6);
|
return std::string(m_diskHeader.begin(), m_diskHeader.begin() + ID_LENGTH);
|
||||||
buffer[6] = 0;
|
|
||||||
|
|
||||||
std::string id = buffer;
|
|
||||||
return id;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CVolumeDirectory::SetUniqueID(std::string _ID)
|
void CVolumeDirectory::SetUniqueID(std::string _ID)
|
||||||
|
|
Loading…
Reference in New Issue