Add unittest for ParseLBN. Seems we already parse correctly.

See #7960
This commit is contained in:
Henrik Rydgård 2015-09-12 11:21:54 +02:00
parent 33c39636c8
commit 1e109a3b27
2 changed files with 51 additions and 17 deletions

View file

@ -31,8 +31,7 @@
const int sectorSize = 2048;
bool parseLBN(std::string filename, u32 *sectorStart, u32 *readSize)
{
bool parseLBN(std::string filename, u32 *sectorStart, u32 *readSize) {
// The format of this is: "/sce_lbn" "0x"? HEX* ANY* "_size" "0x"? HEX* ANY*
// That means that "/sce_lbn/_size1/" is perfectly valid.
// Most commonly, it looks like /sce_lbn0x10_size0x100 or /sce_lbn10_size100 (always hex.)