X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=ncurses%2Ftinfo%2Fsetbuf.c;h=75b952fb33a248c0a95b8de42f88cc12b72faf86;hp=a2e2660c8664909c0f60b1b0f835c8ae36a2156d;hb=03f728e5bb3630a54fffc4a2ff2f8dbfcce9088e;hpb=7f0e189a3cf9bfbb89241cb41db6f2e7672f89f5 diff --git a/ncurses/tinfo/setbuf.c b/ncurses/tinfo/setbuf.c index a2e2660c..75b952fb 100644 --- a/ncurses/tinfo/setbuf.c +++ b/ncurses/tinfo/setbuf.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc. * + * Copyright (c) 1998-2010,2011 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -42,7 +42,7 @@ #include -MODULE_ID("$Id: setbuf.c,v 1.16 2010/08/28 21:08:31 tom Exp $") +MODULE_ID("$Id: setbuf.c,v 1.17 2011/10/22 16:34:50 tom Exp $") /* * If the output file descriptor is connected to a tty (the typical case) it @@ -100,7 +100,7 @@ MODULE_ID("$Id: setbuf.c,v 1.16 2010/08/28 21:08:31 tom Exp $") * buffer. So we disable this by default (there may yet be a workaround). */ NCURSES_EXPORT(void) -NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered) +NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, int buffered) { int Cols; int Lines; @@ -149,7 +149,7 @@ NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered) #ifdef SETVBUF_REVERSED /* pre-svr3? */ (void) setvbuf(ofp, buf_ptr, buf_len, buf_len ? _IOFBF : _IOLBF); #else - (void) setvbuf(ofp, buf_ptr, buf_len ? _IOFBF : _IOLBF, buf_len); + (void) setvbuf(ofp, buf_ptr, buf_len ? _IOFBF : _IOLBF, (size_t) buf_len); #endif #elif HAVE_SETBUFFER (void) setbuffer(ofp, buf_ptr, (int) buf_len); @@ -162,7 +162,7 @@ NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered) #if NCURSES_SP_FUNCS NCURSES_EXPORT(void) -_nc_set_buffer(FILE *ofp, bool buffered) +_nc_set_buffer(FILE *ofp, int buffered) { NCURSES_SP_NAME(_nc_set_buffer) (CURRENT_SCREEN, ofp, buffered); }