Refactor function signatures to use const char* for string parameters

This commit is contained in:
2025-09-30 13:48:31 +01:00
parent fe20a40a0e
commit 352850a698
11 changed files with 59 additions and 60 deletions

View File

@@ -83,7 +83,7 @@ AARU_EXPORT int32_t AARU_CALL aaruf_read_sector(void *context, uint64_t sectorAd
AARU_EXPORT int32_t AARU_CALL aaruf_read_sector_long(void *context, uint64_t sectorAddress, uint8_t *data,
uint32_t *length);
AARU_EXPORT int32_t AARU_CALL aaruf_write_sector(void *context, uint64_t sectorAddress, uint8_t *data,
AARU_EXPORT int32_t AARU_CALL aaruf_write_sector(void *context, uint64_t sectorAddress, const uint8_t *data,
uint8_t sectorStatus, uint32_t length);
AARU_EXPORT int32_t AARU_CALL aaruf_verify_image(void *context);

View File

@@ -27,7 +27,7 @@ struct CacheHeader
* @param key Key
* @return Value if found, NULL if not
*/
void *find_in_cache(struct CacheHeader *cache, char *key);
void *find_in_cache(struct CacheHeader *cache, const char *key);
/**
* Adds an item to the specified cache
@@ -35,7 +35,7 @@ void *find_in_cache(struct CacheHeader *cache, char *key);
* @param key Key
* @param value Value
*/
void add_to_cache(struct CacheHeader *cache, char *key, void *value);
void add_to_cache(struct CacheHeader *cache, const char *key, void *value);
/**
* Finds an item in the specified cache using a 64-bit integer key