mirror of
https://github.com/pbatard/rufus.git
synced 2025-05-19 09:25:12 -04:00
[misc] separated ms-sys dependency from application
* set ms-sys to be built as a library * also removed unused code from badblocks.c
This commit is contained in:
parent
01d1d74f04
commit
dc010cc418
56 changed files with 1129 additions and 459 deletions
27
src/ms-sys/inc/file.h
Normal file
27
src/ms-sys/inc/file.h
Normal file
|
@ -0,0 +1,27 @@
|
|||
#ifndef FILE_H
|
||||
#define FILE_H
|
||||
|
||||
/* Max valid value of uiLen for contains_data */
|
||||
#define MAX_DATA_LEN 4096
|
||||
|
||||
/* Checks if a file contains a data pattern of length uiLen at position
|
||||
ulPositoin. The file pointer will change when calling this function! */
|
||||
int contains_data(FILE *fp, size_t ulPosition,
|
||||
const void *pData, size_t uiLen);
|
||||
|
||||
/* Writes a data pattern of length uiLen at position ulPositoin.
|
||||
The file pointer will change when calling this function! */
|
||||
int write_data(FILE *fp, size_t ulPosition,
|
||||
const void *pData, size_t uiLen);
|
||||
|
||||
/* Writes nSectors of size SectorSize starting at sector StartSector */
|
||||
int write_sectors(void *hDrive, size_t SectorSize,
|
||||
size_t StartSector, size_t nSectors,
|
||||
const void *pBuf);
|
||||
|
||||
/* Reads nSectors of size SectorSize starting at sector StartSector */
|
||||
int read_sectors(void *hDrive, size_t SectorSize,
|
||||
size_t StartSector, size_t nSectors,
|
||||
void *pBuf);
|
||||
|
||||
#endif
|
Loading…
Add table
Add a link
Reference in a new issue