Advertisement
BaSs_HaXoR

C++ (SPRX Load Multiple SPRX's)

Aug 7th, 2014
618
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.43 KB | None | 0 0
  1. //How to read 2 files (SPRX)
  2.  
  3. #include <cell/fs/cell_fs_errno.h>
  4. #include <cell/fs/cell_fs_file_api.h>
  5. int fd;
  6. uint64_t nrw;
  7. char* Read(const char* p,uint64_t nbytes,int64_t offset)
  8. {
  9. char* buff;
  10. cellFsOpen(p,CELL_FS_O_RDWR|CELL_FS_O_CREAT, &fd, NULL, 0);
  11. uint64_t pos;
  12. cellFsLseek(fd, offset, CELL_FS_SEEK_SET, &pos);
  13. cellFsRead(fd, (void *)buff, (uint64_t)nbytes, &nrw);
  14. cellFsClose(fd);
  15. return buff;
  16. }
  17. //Credits: Milky4444
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement