- Timestamp:
- Jan 7, 2011 2:09:52 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Devices/Audio/filteraudio.c
r35419 r35427 334 334 335 335 if (!pVoice->fIntercepted) 336 { 336 337 return filter_conf.pDrv->pcm_ops->run_out(phw); 338 } 337 339 338 340 /* We return the live count in the case we are not initialized. This should … … 409 411 410 412 status = ASMAtomicReadU32(&pVoice->status); 411 if ( status != CA_STATUS_INIT)413 if (!(status == CA_STATUS_INIT)) 412 414 return 0; 413 415 … … 549 551 550 552 /* Iterate as long as data is available */ 551 while 553 while(csWritten < csAvail) 552 554 { 553 555 /* How much is left? */ … … 664 666 int rc = VINF_SUCCESS; 665 667 filterVoiceIn *pVoice; 666 int rcHost = 0;667 668 668 669 if (!filter_conf.pDrv) … … 688 689 /* Note: audio.c does not use variable parameters '...', so ok to forward only 'phw' and 'cmd'. */ 689 690 Log(("FilterAudio: [Input]: forwarding ctl_in ENABLE for voice %p (hw %p)\n", pVoice, pVoice->phw)); 690 if (pVoice->fHostOK) 691 rcHost = filter_conf.pDrv->pcm_ops->ctl_in(phw, cmd); 692 return rcHost; 691 return filter_conf.pDrv->pcm_ops->ctl_in(phw, cmd); 693 692 } 694 693 … … 730 729 if (!pVoice->fIntercepted) 731 730 { 731 if (!pVoice->fHostOK) 732 { 733 /* Host did not initialize the voice. Theoretically should not happen, because 734 * audio.c should not disable a voice which has not been enabled at all. 735 */ 736 Log(("FilterAudio: [Input]: ctl_in DISABLE voice %p (hw %p) not available on host\n", pVoice, pVoice->phw)); 737 return -1; 738 } 739 732 740 /* Note: audio.c does not use variable parameters '...', so ok to forward only 'phw' and 'cmd'. */ 733 741 Log(("FilterAudio: [Input]: forwarding ctl_in DISABLE for voice %p (hw %p)\n", pVoice, pVoice->phw)); 734 if (pVoice->fHostOK) 735 rcHost = filter_conf.pDrv->pcm_ops->ctl_in(phw, cmd); 736 return rcHost; 742 return filter_conf.pDrv->pcm_ops->ctl_in(phw, cmd); 737 743 } 738 744 … … 773 779 774 780 /* Uninitialize both host and filter parts of the voice. */ 775 Log(("FilterAudio: [Input]: forwarding fini_in for voice %p (hw %p)\n", pVoice, pVoice->phw));776 781 if (pVoice->fHostOK) 782 { 783 /* Uninit host part only if it was initialized by host. */ 784 Log(("FilterAudio: [Input]: forwarding fini_in for voice %p (hw %p)\n", pVoice, pVoice->phw)); 777 785 filter_conf.pDrv->pcm_ops->fini_in(phw); 786 } 778 787 779 788 Log(("FilterAudio: [Input]: fini_in for voice %p (hw %p)\n", pVoice, pVoice->phw));
Note:
See TracChangeset
for help on using the changeset viewer.