summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiguel Freitas <miguelfreitas@users.sourceforge.net>2002-04-18 11:42:36 +0000
committerMiguel Freitas <miguelfreitas@users.sourceforge.net>2002-04-18 11:42:36 +0000
commit6bc7b443be9d7cec2235d26c4faad264ec34efad (patch)
tree8e6732ca0b9d27befc431f3a2e866ab295ec5065
parentaaefee31b3a529069218aea70cd849f1b7208d0b (diff)
downloadxine-lib-6bc7b443be9d7cec2235d26c4faad264ec34efad.tar.gz
xine-lib-6bc7b443be9d7cec2235d26c4faad264ec34efad.tar.bz2
Thibaut Mattern's latest patches (xv zoom fix and mms segfault)
CVS patchset: 1735 CVS date: 2002/04/18 11:42:36
-rw-r--r--src/input/mms.c22
-rw-r--r--src/video_out/video_out_xv.c6
2 files changed, 14 insertions, 14 deletions
diff --git a/src/input/mms.c b/src/input/mms.c
index ab5d38a32..16db5b162 100644
--- a/src/input/mms.c
+++ b/src/input/mms.c
@@ -513,21 +513,19 @@ static void interp_header (mms_t *this) {
int mms_url_is(char* url, char** mms_url) {
int i=0;
- char* uptr;
+ int len;
- printf("mms_url_is l=%d \n",strlen(mms_url[0]));
+ printf("libmms: mms_url_is l=%d \n",strlen(mms_url[0]));
if(!url )
return 0;
- uptr=strdup(url);
- uptr=strupr(uptr);
+
while(mms_url[i]){
- if(!strncasecmp(uptr,mms_url[i],strlen(mms_url[i]) )){
- free(uptr);
- return strlen(mms_url[i]);
+ len = strlen(mms_url[i]);
+ if(!strncasecmp(url, mms_url[i], len)){
+ return len;
}
i++;
}
- free(uptr);
return 0;
}
@@ -606,13 +604,14 @@ char* mms_connect_common(int *s, int port, char *url, char **host, char** hosten
* try to connect
*/
- printf("here port=%d \n",port);
+ printf("libmms: try to connect to %s on port %d \n", *host, port);
*s = host_connect (*host, port);
if (*s == -1) {
printf ("libmms: failed to connect\n");
free (*host);
return NULL;
}
+ printf ("libmms: connected\n");
return url;
}
@@ -652,7 +651,8 @@ mms_t *mms_connect (char *url_) {
this->buf_size = 0;
this->buf_read = 0;
- printf ("%s %s %s %s ",url,host,path,file);
+ printf ("libmms: url=%s\nlibmms: host=%s\nlibmms: "
+ "path=%s\nlibmms: file=%s\n", url, host, path, file);
/*
* let the negotiations begin...
*/
@@ -665,7 +665,7 @@ mms_t *mms_connect (char *url_) {
send_command (this, 1, 0, 0x0004000b, strlen(this->str) * 2+8);
- printf("before read \n");
+ printf("libmms: before read \n");
len = read (this->s, this->buf, BUF_SIZE) ;
if (len>0)
print_answer (this->buf, len);
diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c
index 4fedc7297..4770618d5 100644
--- a/src/video_out/video_out_xv.c
+++ b/src/video_out/video_out_xv.c
@@ -17,7 +17,7 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
*
- * $Id: video_out_xv.c,v 1.111 2002/04/02 19:29:09 esnel Exp $
+ * $Id: video_out_xv.c,v 1.112 2002/04/18 11:42:38 miguelfreitas Exp $
*
* video_out_xv.c, X11 video extension interface for xine
*
@@ -695,11 +695,11 @@ static void xv_compute_output_size (xv_driver_t *this) {
y_factor = (double) this->gui_height / (double) this->ideal_height;
if ( x_factor < y_factor ) {
- this->output_width = (double) this->ideal_width * x_factor ;
+ this->output_width = (double) this->gui_width;
this->output_height = (double) this->ideal_height * x_factor ;
} else {
this->output_width = (double) this->ideal_width * y_factor ;
- this->output_height = (double) this->ideal_height * y_factor ;
+ this->output_height = (double) this->gui_height;
}
this->output_xoffset = (this->gui_width - this->output_width) / 2 + this->gui_x;