Pārlūkot izejas kodu

cmAudioPort.c: Added cmApFileAllocate() to cmApPortTest().

Verified ALSA is working with cmApPortTest()
master
kevin 11 gadus atpakaļ
vecāks
revīzija
6d0d9005c8
1 mainītis faili ar 8 papildinājumiem un 0 dzēšanām
  1. 8
    0
      cmAudioPort.c

+ 8
- 0
cmAudioPort.c Parādīt failu

693
 
693
 
694
   cmRptPrintf(rpt,"%s in:%i out:%i chidx:%i chs:%i bufs=%i frm=%i rate=%f\n",runFl?"exec":"rpt",r.inDevIdx,r.outDevIdx,r.chIdx,r.chCnt,r.bufCnt,r.framesPerCycle,r.srate);
694
   cmRptPrintf(rpt,"%s in:%i out:%i chidx:%i chs:%i bufs=%i frm=%i rate=%f\n",runFl?"exec":"rpt",r.inDevIdx,r.outDevIdx,r.chIdx,r.chCnt,r.bufCnt,r.framesPerCycle,r.srate);
695
 
695
 
696
+  if( cmApFileAllocate(rpt) != kOkApRC )
697
+  {
698
+    cmRptPrintf(rpt,"Audio port file allocation failed.");
699
+    result = -1;
700
+    goto errLabel;
701
+  }
702
+
696
   // allocate the non-real-time port
703
   // allocate the non-real-time port
697
   if( cmApNrtAllocate(rpt) != kOkApRC )
704
   if( cmApNrtAllocate(rpt) != kOkApRC )
698
   {
705
   {
796
   cmApBufFinalize();
803
   cmApBufFinalize();
797
 
804
 
798
   cmApNrtFree();
805
   cmApNrtFree();
806
+  cmApFileFree();
799
 
807
 
800
   // report the count of audio buffer callbacks
808
   // report the count of audio buffer callbacks
801
   cmRptPrintf(rpt,"cb count:%i\n", r.cbCnt );
809
   cmRptPrintf(rpt,"cb count:%i\n", r.cbCnt );

Notiek ielāde…
Atcelt
Saglabāt