Update 'cv7/a_station.c'
This commit is contained in:
parent
8959ee7231
commit
1cb87c3c0d
@ -25,12 +25,9 @@ void destroy_station(struct station* station){
|
|||||||
}
|
}
|
||||||
|
|
||||||
int select_track(struct station* station, const char* target){
|
int select_track(struct station* station, const char* target){
|
||||||
if (isalpha(target[0])) {
|
if (isalpha(target[0])) {
|
||||||
if (isupper(target[0])) {
|
char first_letter = tolower(target[0]);
|
||||||
return target[0] - 'A';
|
return first_letter - 'a';
|
||||||
} else {
|
|
||||||
return target[0] - 'a';
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user