mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-16 19:43:06 +01:00
Handle nullptr for object when getting track designs
This commit is contained in:
@@ -374,13 +374,13 @@ extern "C"
|
||||
size_t track_repository_get_count_for_ride(uint8 rideType, const utf8 * entry)
|
||||
{
|
||||
ITrackDesignRepository * repo = GetTrackDesignRepository();
|
||||
return repo->GetCountForObjectEntry(rideType, entry);
|
||||
return repo->GetCountForObjectEntry(rideType, String::ToStd(entry));
|
||||
}
|
||||
|
||||
size_t track_repository_get_items_for_ride(track_design_file_ref * * outRefs, uint8 rideType, const utf8 * entry)
|
||||
{
|
||||
ITrackDesignRepository * repo = GetTrackDesignRepository();
|
||||
return repo->GetItemsForObjectEntry(outRefs, rideType, entry);
|
||||
return repo->GetItemsForObjectEntry(outRefs, rideType, String::ToStd(entry));
|
||||
}
|
||||
|
||||
bool track_repository_delete(const utf8 * path)
|
||||
|
||||
Reference in New Issue
Block a user