aboutsummaryrefslogtreecommitdiffstats
path: root/core.c
diff options
context:
space:
mode:
Diffstat (limited to 'core.c')
-rw-r--r--core.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/core.c b/core.c
index 35998c0..a733118 100644
--- a/core.c
+++ b/core.c
@@ -210,10 +210,10 @@ static void pcm_private_data_free(struct snd_pcm *pcm)
{
struct snd_avirt_private_data *avirt_private_data;
- D_PRINTK("Issuing free to private data struct");
- if (pcm->private_data) {
- avirt_private_data = pcm->private_data;
- if (avirt_private_data->ap_private_data)
+ avirt_private_data = (struct snd_avirt_private_data *)pcm->private_data;
+ if (avirt_private_data) {
+ if (avirt_private_data->ap_private_data &&
+ avirt_private_data->ap_private_free)
avirt_private_data->ap_private_free(pcm);
}