diff options
| author | spicyjpeg <88942473+spicyjpeg@users.noreply.github.com> | 2021-12-23 22:09:06 +0100 |
|---|---|---|
| committer | spicyjpeg <88942473+spicyjpeg@users.noreply.github.com> | 2021-12-23 22:09:06 +0100 |
| commit | 2e6625481cd006d0a9d68285ce557f195030718e (patch) | |
| tree | 5a65f290c20cde7a34ceb95fc40f0945ba5968d7 /libpsn00b/psxcd/psxcd.c | |
| parent | 6c7512ff42805e9399dfee8b67e2f70fa55909d3 (diff) | |
| download | psn00bsdk-2e6625481cd006d0a9d68285ce557f195030718e.tar.gz | |
Fix CdGetSector size inconsistency, update changelog
Diffstat (limited to 'libpsn00b/psxcd/psxcd.c')
| -rw-r--r-- | libpsn00b/psxcd/psxcd.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libpsn00b/psxcd/psxcd.c b/libpsn00b/psxcd/psxcd.c index 74c6c1c..76415f9 100644 --- a/libpsn00b/psxcd/psxcd.c +++ b/libpsn00b/psxcd/psxcd.c @@ -255,7 +255,7 @@ static void _CdReadReadyCallback(int status, unsigned char *result) CdGetSector((void*)_cd_read_addr, _cd_read_sector_sz); // Increment destination address - _cd_read_addr += _cd_read_sector_sz>>2; + _cd_read_addr += _cd_read_sector_sz; // Subtract sector count _cd_sector_count--; @@ -290,15 +290,15 @@ int CdRead(int sectors, u_long *buf, int mode) // Determine sector based on mode flags if( mode & CdlModeSize0 ) { - _cd_read_sector_sz = 2328; + _cd_read_sector_sz = 2328 / 4; } else if( mode & CdlModeSize1 ) { - _cd_read_sector_sz = 2340; + _cd_read_sector_sz = 2340 / 4; } else { - _cd_read_sector_sz = 2048; + _cd_read_sector_sz = 2048 / 4; } _cd_read_counter = VSync(-1); |
