devaudio: ignore non absolute volume items with range 0
This commit is contained in:
parent
7b6c150f5d
commit
a7a56b9a48
1 changed files with 2 additions and 0 deletions
|
@ -363,6 +363,8 @@ genaudiovolread(Audio *adev, void *a, long n, vlong,
|
|||
if(vol[i].type == Absolute)
|
||||
p += snprint(p, e - p, "%s %d\n", vol[i].name, v[0]);
|
||||
else {
|
||||
if(vol[i].range == 0)
|
||||
continue;
|
||||
for(j=0; j<2; j++){
|
||||
if(v[j] < 0)
|
||||
v[j] = 0;
|
||||
|
|
Loading…
Reference in a new issue