mirror of
https://github.com/monero-project/monero.git
synced 2024-12-22 11:39:28 +00:00
Merge pull request #8358
fb3f7ce
clang warning fix for #8338 (Jeffrey Ryan)
This commit is contained in:
commit
aa0b4fc7cc
1 changed files with 4 additions and 0 deletions
|
@ -44,12 +44,16 @@ reverse_bytes(signed char size, char *address){
|
|||
char * first = address;
|
||||
char * last = first + size - 1;
|
||||
for(;first < last;++first, --last){
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wstringop-overflow="
|
||||
#endif
|
||||
char x = *last;
|
||||
*last = *first;
|
||||
*first = x;
|
||||
#if defined(__GNUC__) && !defined(__clang__)
|
||||
#pragma GCC diagnostic pop
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue