mirror of
https://github.com/n5ac/smartsdr-dsp.git
synced 2026-04-07 07:13:53 +00:00
Replace spaces in string parsing with non-printable 0x7F for correct passthrough in radio
This commit is contained in:
parent
637e3376a0
commit
5cd5b63b7e
5 changed files with 27 additions and 2 deletions
|
|
@ -140,3 +140,19 @@ void printIP(uint32 ip)
|
|||
output("%d.%d.%d.%d\n",((ip>>24)& 0xFF),((ip>>16)& 0xFF),((ip>>8)& 0xFF),(ip & 0xFF));
|
||||
}
|
||||
|
||||
void charReplace( char * string, char oldChar, char newChar )
|
||||
{
|
||||
if ( string == NULL ) {
|
||||
output("Null string passed to charReplace\n");
|
||||
return ;
|
||||
}
|
||||
|
||||
while (*string != 0 ) {
|
||||
if ( *string == oldChar )
|
||||
*string = newChar;
|
||||
|
||||
string++;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue