Mercurial > mplayer.hg
comparison stream/stream_dvb.c @ 25380:5857ec4dedb4
removed the obscene priv->stream entry. Someone must have injected vodka in my milk when I wrote it
author | nicodvb |
---|---|
date | Sat, 15 Dec 2007 13:37:41 +0000 |
parents | 9befb9809011 |
children | cd65c1242675 |
comparison
equal
deleted
inserted
replaced
25379:9befb9809011 | 25380:5857ec4dedb4 |
---|---|
624 priv->is_on = 0; | 624 priv->is_on = 0; |
625 dvb_free_config(priv->config); | 625 dvb_free_config(priv->config); |
626 } | 626 } |
627 | 627 |
628 | 628 |
629 static int dvb_streaming_start(dvb_priv_t *priv, struct stream_priv_s *opts, int tuner_type, char *progname) | 629 static int dvb_streaming_start(stream_t *stream, struct stream_priv_s *opts, int tuner_type, char *progname) |
630 { | 630 { |
631 int i; | 631 int i; |
632 dvb_channel_t *channel = NULL; | 632 dvb_channel_t *channel = NULL; |
633 stream_t *stream = (stream_t*) priv->stream; | 633 dvb_priv_t *priv = stream->priv; |
634 | 634 |
635 mp_msg(MSGT_DEMUX, MSGL_V, "\r\ndvb_streaming_start(PROG: %s, CARD: %d, VID: %d, AID: %d, TYPE: %s, FILE: %s)\r\n", | 635 mp_msg(MSGT_DEMUX, MSGL_V, "\r\ndvb_streaming_start(PROG: %s, CARD: %d, VID: %d, AID: %d, TYPE: %s, FILE: %s)\r\n", |
636 opts->prog, opts->card, opts->vid, opts->aid, opts->type, opts->file); | 636 opts->prog, opts->card, opts->vid, opts->aid, opts->type, opts->file); |
637 | 637 |
638 priv->is_on = 0; | 638 priv->is_on = 0; |
689 stream->priv = calloc(1, sizeof(dvb_priv_t)); | 689 stream->priv = calloc(1, sizeof(dvb_priv_t)); |
690 if(stream->priv == NULL) | 690 if(stream->priv == NULL) |
691 return STREAM_ERROR; | 691 return STREAM_ERROR; |
692 | 692 |
693 priv = (dvb_priv_t *)stream->priv; | 693 priv = (dvb_priv_t *)stream->priv; |
694 priv->stream = stream; | |
695 priv->config = dvb_get_config(); | 694 priv->config = dvb_get_config(); |
696 if(priv->config == NULL) | 695 if(priv->config == NULL) |
697 { | 696 { |
698 free(priv); | 697 free(priv); |
699 mp_msg(MSGT_DEMUX, MSGL_ERR, "DVB CONFIGURATION IS EMPTY, exit\n"); | 698 mp_msg(MSGT_DEMUX, MSGL_ERR, "DVB CONFIGURATION IS EMPTY, exit\n"); |
739 progname = priv->list->channels[0].name; | 738 progname = priv->list->channels[0].name; |
740 else | 739 else |
741 progname = p->prog; | 740 progname = p->prog; |
742 | 741 |
743 | 742 |
744 if(! dvb_streaming_start(priv, p, tuner_type, progname)) | 743 if(! dvb_streaming_start(stream, p, tuner_type, progname)) |
745 { | 744 { |
746 free(stream->priv); | 745 free(stream->priv); |
747 stream->priv = NULL; | 746 stream->priv = NULL; |
748 return STREAM_ERROR; | 747 return STREAM_ERROR; |
749 } | 748 } |