Changeset 676
- Timestamp:
- 12/18/09 06:15:38 (2 years ago)
- Files:
-
- sweep/trunk/src/driver_alsa.c (modified) (4 diffs)
- sweep/trunk/src/driver_oss.c (modified) (4 diffs)
- sweep/trunk/src/driver_solaris.c (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
sweep/trunk/src/driver_alsa.c
r674 r676 65 65 #endif 66 66 67 static sw_handle alsa_handle = { 68 0, -1, 0, 0, NULL 69 }; 70 71 67 72 void print_pcm_state (snd_pcm_t * pcm) 68 73 { … … 124 129 char * alsa_pcm_name; 125 130 snd_pcm_t * pcm_handle; 126 sw_handle * handle ;131 sw_handle * handle = &alsa_handle; 127 132 snd_pcm_stream_t stream; 128 133 … … 150 155 return NULL; 151 156 } 152 153 handle = g_malloc0 (sizeof (sw_handle));154 157 155 158 handle->driver_flags = flags; … … 444 447 445 448 snd_pcm_close (pcm_handle); 449 handle->custom_data = NULL; 446 450 } 447 451 sweep/trunk/src/driver_oss.c
r674 r676 77 77 static int frame; 78 78 79 79 static sw_handle oss_handle = { 80 0, -1, 0, 0, NULL 81 }; 80 82 81 83 /* driver functions */ … … 98 100 char * dev_name; 99 101 int dev_dsp; 100 sw_handle * handle ;102 sw_handle * handle = &oss_handle; 101 103 int i; 102 104 … … 117 119 } 118 120 119 handle = g_malloc0 (sizeof (sw_handle));120 121 handle->driver_flags = flags; 121 122 handle->driver_fd = dev_dsp; … … 431 432 { 432 433 close (handle->driver_fd); 434 handle->driver_fd = -1; 433 435 } 434 436 sweep/trunk/src/driver_solaris.c
r674 r676 48 48 #define DEV_AUDIO "/dev/audio" 49 49 50 static sw_handle dev_audio_handle = { 51 0, -1, 0, 0, NULL 52 }; 53 50 54 static sw_handle * 51 55 open_dev_audio (int cueing, int flags) 52 56 { 53 57 int dev_audio; 54 sw_handle * handle ;58 sw_handle * handle = &dev_audio_handle; 55 59 56 60 if (cueing) return NULL; … … 61 65 } 62 66 63 handle = g_malloc0 (sizeof (sw_handle));64 67 handle->driver_flags = flags; 65 68 handle->driver_fd = dev_audio; … … 113 116 { 114 117 close (handle->driver_fd); 118 handle->driver_fd = -1; 115 119 } 116 120
