diff mbox

[2/4] use C99 initializers for audio_pcm_ops

Message ID ca6c5bf659b2e267092b2996bf81ff76809aa57b.1249950639.git.quintela@redhat.com
State Superseded
Headers show

Commit Message

Juan Quintela Aug. 11, 2009, 12:31 a.m. UTC
Signed-off-by: Juan Quintela <quintela@redhat.com>
---
 audio/alsaaudio.c   |   22 +++++++++++-----------
 audio/coreaudio.c   |   16 +++++-----------
 audio/dsoundaudio.c |   22 +++++++++++-----------
 audio/esdaudio.c    |   22 +++++++++++-----------
 audio/fmodaudio.c   |   22 +++++++++++-----------
 audio/noaudio.c     |   22 +++++++++++-----------
 audio/ossaudio.c    |   22 +++++++++++-----------
 audio/paaudio.c     |   21 +++++++++++----------
 audio/sdlaudio.c    |   16 +++++-----------
 audio/wavaudio.c    |   16 +++++-----------
 10 files changed, 92 insertions(+), 109 deletions(-)
diff mbox

Patch

diff --git a/audio/alsaaudio.c b/audio/alsaaudio.c
index 61a8cd0..71a8c89 100644
--- a/audio/alsaaudio.c
+++ b/audio/alsaaudio.c
@@ -969,17 +969,17 @@  static struct audio_option alsa_options[] = {
 };

 static struct audio_pcm_ops alsa_pcm_ops = {
-    alsa_init_out,
-    alsa_fini_out,
-    alsa_run_out,
-    alsa_write,
-    alsa_ctl_out,
-
-    alsa_init_in,
-    alsa_fini_in,
-    alsa_run_in,
-    alsa_read,
-    alsa_ctl_in
+    .init_out = alsa_init_out,
+    .fini_out = alsa_fini_out,
+    .run_out  = alsa_run_out,
+    .write    = alsa_write,
+    .ctl_out  = alsa_ctl_out,
+
+    .init_in  = alsa_init_in,
+    .fini_in  = alsa_fini_in,
+    .run_in   = alsa_run_in,
+    .read     = alsa_read,
+    .ctl_in   = alsa_ctl_in
 };

 struct audio_driver alsa_audio_driver = {
diff --git a/audio/coreaudio.c b/audio/coreaudio.c
index c46b357..9a9754d 100644
--- a/audio/coreaudio.c
+++ b/audio/coreaudio.c
@@ -521,17 +521,11 @@  static struct audio_option coreaudio_options[] = {
 };

 static struct audio_pcm_ops coreaudio_pcm_ops = {
-    coreaudio_init_out,
-    coreaudio_fini_out,
-    coreaudio_run_out,
-    coreaudio_write,
-    coreaudio_ctl_out,
-
-    NULL,
-    NULL,
-    NULL,
-    NULL,
-    NULL
+    .init_out = coreaudio_init_out,
+    .fini_out = coreaudio_fini_out,
+    .run_out  = coreaudio_run_out,
+    .write    = coreaudio_write,
+    .ctl_out  = coreaudio_ctl_out
 };

 struct audio_driver coreaudio_audio_driver = {
diff --git a/audio/dsoundaudio.c b/audio/dsoundaudio.c
index 7c08790..a8edfee 100644
--- a/audio/dsoundaudio.c
+++ b/audio/dsoundaudio.c
@@ -1059,17 +1059,17 @@  static struct audio_option dsound_options[] = {
 };

 static struct audio_pcm_ops dsound_pcm_ops = {
-    dsound_init_out,
-    dsound_fini_out,
-    dsound_run_out,
-    dsound_write,
-    dsound_ctl_out,
-
-    dsound_init_in,
-    dsound_fini_in,
-    dsound_run_in,
-    dsound_read,
-    dsound_ctl_in
+    .init_out = dsound_init_out,
+    .fini_out = dsound_fini_out,
+    .run_out  = dsound_run_out,
+    .write    = dsound_write,
+    .ctl_out  = dsound_ctl_out,
+
+    .init_in  = dsound_init_in,
+    .fini_in  = dsound_fini_in,
+    .run_in   = dsound_run_in,
+    .read     = dsound_read,
+    .ctl_in   = dsound_ctl_in
 };

 struct audio_driver dsound_audio_driver = {
diff --git a/audio/esdaudio.c b/audio/esdaudio.c
index ff6725e..29f4ffc 100644
--- a/audio/esdaudio.c
+++ b/audio/esdaudio.c
@@ -567,17 +567,17 @@  struct audio_option qesd_options[] = {
 };

 static struct audio_pcm_ops qesd_pcm_ops = {
-    qesd_init_out,
-    qesd_fini_out,
-    qesd_run_out,
-    qesd_write,
-    qesd_ctl_out,
-
-    qesd_init_in,
-    qesd_fini_in,
-    qesd_run_in,
-    qesd_read,
-    qesd_ctl_in,
+    .init_out = qesd_init_out,
+    .fini_out = qesd_fini_out,
+    .run_out  = qesd_run_out,
+    .write    = qesd_write,
+    .ctl_out  = qesd_ctl_out,
+
+    .init_in  = qesd_init_in,
+    .fini_in  = qesd_fini_in,
+    .run_in   = qesd_run_in,
+    .read     = qesd_read,
+    .ctl_in   = qesd_ctl_in,
 };

 struct audio_driver esd_audio_driver = {
diff --git a/audio/fmodaudio.c b/audio/fmodaudio.c
index 8259551..83a6454 100644
--- a/audio/fmodaudio.c
+++ b/audio/fmodaudio.c
@@ -658,17 +658,17 @@  static struct audio_option fmod_options[] = {
 };

 static struct audio_pcm_ops fmod_pcm_ops = {
-    fmod_init_out,
-    fmod_fini_out,
-    fmod_run_out,
-    fmod_write,
-    fmod_ctl_out,
-
-    fmod_init_in,
-    fmod_fini_in,
-    fmod_run_in,
-    fmod_read,
-    fmod_ctl_in
+    .init_out = fmod_init_out,
+    .fini_out = fmod_fini_out,
+    .run_out  = fmod_run_out,
+    .write    = fmod_write,
+    .ctl_out  = fmod_ctl_out,
+
+    .init_in = fmod_init_in,
+    .fini_in = fmod_fini_in,
+    .run_in  = fmod_run_in,
+    .read    = fmod_read,
+    .ctl_in  = fmod_ctl_in
 };

 struct audio_driver fmod_audio_driver = {
diff --git a/audio/noaudio.c b/audio/noaudio.c
index 1a7529a..40a1a2f 100644
--- a/audio/noaudio.c
+++ b/audio/noaudio.c
@@ -146,17 +146,17 @@  static void no_audio_fini (void *opaque)
 }

 static struct audio_pcm_ops no_pcm_ops = {
-    no_init_out,
-    no_fini_out,
-    no_run_out,
-    no_write,
-    no_ctl_out,
-
-    no_init_in,
-    no_fini_in,
-    no_run_in,
-    no_read,
-    no_ctl_in
+    .init_out = no_init_out,
+    .fini_out = no_fini_out,
+    .run_out  = no_run_out,
+    .write    = no_write,
+    .ctl_out  = no_ctl_out,
+
+    .init_in  = no_init_in,
+    .fini_in  = no_fini_in,
+    .run_in   = no_run_in,
+    .read     = no_read,
+    .ctl_in   = no_ctl_in
 };

 struct audio_driver no_audio_driver = {
diff --git a/audio/ossaudio.c b/audio/ossaudio.c
index 97edf9f..1c2c584 100644
--- a/audio/ossaudio.c
+++ b/audio/ossaudio.c
@@ -752,17 +752,17 @@  static struct audio_option oss_options[] = {
 };

 static struct audio_pcm_ops oss_pcm_ops = {
-    oss_init_out,
-    oss_fini_out,
-    oss_run_out,
-    oss_write,
-    oss_ctl_out,
-
-    oss_init_in,
-    oss_fini_in,
-    oss_run_in,
-    oss_read,
-    oss_ctl_in
+    .init_out = oss_init_out,
+    .fini_out = oss_fini_out,
+    .run_out  = oss_run_out,
+    .write    = oss_write,
+    .ctl_out  = oss_ctl_out,
+
+    .init_in  = oss_init_in,
+    .fini_in  = oss_fini_in,
+    .run_in   = oss_run_in,
+    .read     = oss_read,
+    .ctl_in   = oss_ctl_in
 };

 struct audio_driver oss_audio_driver = {
diff --git a/audio/paaudio.c b/audio/paaudio.c
index 0b469cf..43b3002 100644
--- a/audio/paaudio.c
+++ b/audio/paaudio.c
@@ -488,16 +488,17 @@  struct audio_option qpa_options[] = {
 };

 static struct audio_pcm_ops qpa_pcm_ops = {
-    qpa_init_out,
-    qpa_fini_out,
-    qpa_run_out,
-    qpa_write,
-    qpa_ctl_out,
-    qpa_init_in,
-    qpa_fini_in,
-    qpa_run_in,
-    qpa_read,
-    qpa_ctl_in
+    .init_out = qpa_init_out,
+    .fini_out = qpa_fini_out,
+    .run_out  = qpa_run_out,
+    .write    = qpa_write,
+    .ctl_out  = qpa_ctl_out,
+
+    .init_in  = qpa_init_in,
+    .fini_in  = qpa_fini_in,
+    .run_in   = qpa_run_in,
+    .read     = qpa_read,
+    .ctl_in   = qpa_ctl_in
 };

 struct audio_driver pa_audio_driver = {
diff --git a/audio/sdlaudio.c b/audio/sdlaudio.c
index 6870fdf..86e30e3 100644
--- a/audio/sdlaudio.c
+++ b/audio/sdlaudio.c
@@ -426,17 +426,11 @@  static struct audio_option sdl_options[] = {
 };

 static struct audio_pcm_ops sdl_pcm_ops = {
-    sdl_init_out,
-    sdl_fini_out,
-    sdl_run_out,
-    sdl_write_out,
-    sdl_ctl_out,
-
-    NULL,
-    NULL,
-    NULL,
-    NULL,
-    NULL
+    .init_out = sdl_init_out,
+    .fini_out = sdl_fini_out,
+    .run_out  = sdl_run_out,
+    .write    = sdl_write_out,
+    .ctl_out  = sdl_ctl_out,
 };

 struct audio_driver sdl_audio_driver = {
diff --git a/audio/wavaudio.c b/audio/wavaudio.c
index 96cc49d..d5585e4 100644
--- a/audio/wavaudio.c
+++ b/audio/wavaudio.c
@@ -234,17 +234,11 @@  static struct audio_option wav_options[] = {
 };

 static struct audio_pcm_ops wav_pcm_ops = {
-    wav_init_out,
-    wav_fini_out,
-    wav_run_out,
-    wav_write_out,
-    wav_ctl_out,
-
-    NULL,
-    NULL,
-    NULL,
-    NULL,
-    NULL
+    .init_out = wav_init_out,
+    .fini_out = wav_fini_out,
+    .run_out  = wav_run_out,
+    .write    = wav_write_out,
+    .ctl_out  = wav_ctl_out,
 };

 struct audio_driver wav_audio_driver = {