mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-05-15 05:02:13 -04:00
Make assorted arguments pass-by-reference.
This commit is contained in:
parent
a9451c17b4
commit
3172fb1ad6
7 changed files with 13 additions and 13 deletions
|
@ -25,7 +25,7 @@ File::~File() {
|
|||
close();
|
||||
}
|
||||
|
||||
bool File::open_for_append(const std::string file_path) {
|
||||
bool File::open_for_append(const std::string& file_path) {
|
||||
const auto open_result = f_open(&f, file_path.c_str(), FA_WRITE | FA_OPEN_ALWAYS);
|
||||
if( open_result == FR_OK ) {
|
||||
const auto seek_result = f_lseek(&f, f_size(&f));
|
||||
|
@ -60,7 +60,7 @@ bool File::write(const void* const data, const size_t bytes_to_write) {
|
|||
return (result == FR_OK) && (bytes_written == bytes_to_write);
|
||||
}
|
||||
|
||||
bool File::puts(const std::string string) {
|
||||
bool File::puts(const std::string& string) {
|
||||
const auto result = f_puts(string.c_str(), &f);
|
||||
return (result >= 0);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue