* winsup.api/crlf.c: Fix C signed/unsigned compare warning.

* winsup.api/mmaptest01.c: Ditto.
	* winsup.api/ltp/chmod01.c: Ditto.
	* winsup.api/ltp/fork04.c: Ditto.
	* winsup.api/ltp/lseek03.c: Ditto.
	* winsup.api/ltp/lseek06.c: Ditto.
	* winsup.api/ltp/lseek07.c: Ditto.
	* winsup.api/ltp/lseek08.c: Ditto.
	* winsup.api/ltp/mmap001.c: Ditto.
	* winsup.api/ltp/mmap02.c: Ditto.
	* winsup.api/ltp/mmap03.c: Ditto.
	* winsup.api/ltp/mmap04.c: Ditto.
	* winsup.api/ltp/mmap05.c: Ditto.
	* winsup.api/ltp/mmap06.c: Ditto.
	* winsup.api/ltp/mmap07.c: Ditto.
	* winsup.api/ltp/mmap08.c: Ditto.
	* winsup.api/ltp/pipe11.c: Ditto.
	* winsup.api/ltp/poll01.c: Ditto.
	* winsup.api/ltp/sync02.c: Ditto.
	* winsup.api/ltp/times03.c: Ditto.
	* winsup.api/ltp/umask03.c: Ditto.
	* winsup.api/ltp/getpgid01.c: Remove unused obsolete include.
	* winsup.api/ltp/getpgid02.c: Ditto.
This commit is contained in:
Corinna Vinschen 2003-02-20 11:22:17 +00:00
parent 3a88cf1b10
commit 1374b148ba
24 changed files with 54 additions and 28 deletions

View File

@ -1,3 +1,29 @@
2003-02-19 Vaclav Haisman <V.Haisman@sh.cvut.cz>
* winsup.api/crlf.c: Fix C signed/unsigned compare warning.
* winsup.api/mmaptest01.c: Ditto.
* winsup.api/ltp/chmod01.c: Ditto.
* winsup.api/ltp/fork04.c: Ditto.
* winsup.api/ltp/lseek03.c: Ditto.
* winsup.api/ltp/lseek06.c: Ditto.
* winsup.api/ltp/lseek07.c: Ditto.
* winsup.api/ltp/lseek08.c: Ditto.
* winsup.api/ltp/mmap001.c: Ditto.
* winsup.api/ltp/mmap02.c: Ditto.
* winsup.api/ltp/mmap03.c: Ditto.
* winsup.api/ltp/mmap04.c: Ditto.
* winsup.api/ltp/mmap05.c: Ditto.
* winsup.api/ltp/mmap06.c: Ditto.
* winsup.api/ltp/mmap07.c: Ditto.
* winsup.api/ltp/mmap08.c: Ditto.
* winsup.api/ltp/pipe11.c: Ditto.
* winsup.api/ltp/poll01.c: Ditto.
* winsup.api/ltp/sync02.c: Ditto.
* winsup.api/ltp/times03.c: Ditto.
* winsup.api/ltp/umask03.c: Ditto.
* winsup.api/ltp/getpgid01.c: Remove unused obsolete include.
* winsup.api/ltp/getpgid02.c: Ditto.
2003-02-08 Christopher Faylor <cgf@redhat.com>
* winsup.api/winsup.exp (ws_spawn): Tweak slightly to work with tcl

View File

@ -156,7 +156,7 @@ int commands[] = {
int errors = 0;
#define num_commands (sizeof(commands)/sizeof(commands[0]))
#define num_commands (int)(sizeof(commands)/sizeof(commands[0]))
int pc;
int askfor, get, expect, count, posn, whence, size;

View File

@ -96,7 +96,7 @@ main(int ac, char **av)
int lc; /* loop counter */
const char *msg; /* message returned from parse_opts */
int ind; /* counter variable for chmod(2) tests */
int mode; /* file mode permission */
unsigned mode; /* file mode permission */
TST_TOTAL = sizeof(Modes) / sizeof(int);

View File

@ -129,7 +129,7 @@ extern int Tst_count; /* Test Case counter for tst_* routines */
/* list of environment variables to test */
const char *environ_list[] = {"TERM","NoTSetzWq","TESTPROG"};
#define NUMBER_OF_ENVIRON sizeof(environ_list)/sizeof(char *)
#define NUMBER_OF_ENVIRON (int)(sizeof(environ_list)/sizeof(char *))
int TST_TOTAL=NUMBER_OF_ENVIRON; /* Total number of test cases. */
/***************************************************************

View File

@ -44,7 +44,6 @@
#include <sys/types.h>
#include <errno.h>
#include <varargs.h>
#include <sys/wait.h>
#include <test.h>
#include <usctest.h>

View File

@ -46,7 +46,6 @@
#include <sys/types.h>
#include <errno.h>
#include <varargs.h>
#include <sys/wait.h>
#include <test.h>
#include <usctest.h>

View File

@ -137,7 +137,7 @@ main(int ac, char **av)
int lc; /* loop counter */
const char *msg; /* message returned from parse_opts */
int ind;
unsigned ind;
int whence;
TST_TOTAL=sizeof(Whences)/sizeof(int);

View File

@ -201,7 +201,7 @@ setup()
}
/* Write data into temporary file */
if(write(fildes, write_buf, strlen(write_buf)) != strlen(write_buf)) {
if(write(fildes, write_buf, strlen(write_buf)) != (int)strlen(write_buf)) {
tst_brkm(TBROK, cleanup, "write(2) on %s Failed, errno=%d : %s",
TEMP_FILE, errno, strerror(errno));
}

View File

@ -149,7 +149,7 @@ main(int ac, char **av)
* the current offset position.
*/
if (write(fildes, write_buf2, strlen(write_buf2)) !=
strlen(write_buf2)) {
(int)strlen(write_buf2)) {
tst_brkm(TFAIL, cleanup, "write() failed to "
"write additional data, error = %d",
errno);
@ -244,7 +244,7 @@ setup()
/* Write data into temporary file */
if(write(fildes, write_buf1, strlen(write_buf1)) !=
strlen(write_buf1)) {
(int)strlen(write_buf1)) {
tst_brkm(TBROK, cleanup, "write(2) on %s Failed, errno=%d : %s",
TEMP_FILE, errno, strerror(errno));
}

View File

@ -84,7 +84,7 @@ const char *TCID="lseek03"; /* Test program identifier. */
int TST_TOTAL=1; /* Total number of test cases. */
extern int Tst_count; /* Test Case counter for tst_* routines */
int fildes; /* file handle for temp file */
size_t file_size; /* size of the temporary file */
ssize_t file_size; /* size of the temporary file */
void setup(); /* Main setup function of test */
void cleanup(void) __attribute__((noreturn)); /* cleanup function for the test */

View File

@ -90,7 +90,7 @@ int main(int argc, char * argv[])
const char *msg;
int i,lc;
int fd;
unsigned int pages,memsize;
int pages,memsize;
if ( (msg=parse_opts(argc, argv, options, help)) != (char *) NULL )
tst_brkm(TBROK, cleanup, "OPTION PARSING ERROR - %s", msg);

View File

@ -225,7 +225,7 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, sizeof(tst_buff)) < sizeof(tst_buff)) {
if (write(fildes, tst_buff, sizeof(tst_buff)) < (int)sizeof(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -225,7 +225,7 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) < strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff)) < (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -225,7 +225,7 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) < strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff)) < (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -228,7 +228,8 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) != strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff))
!= (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -197,7 +197,7 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) < strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff)) < (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL,
"write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));

View File

@ -198,7 +198,7 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) < strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff)) < (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -191,7 +191,8 @@ setup()
}
/* Write test buffer contents into temporary file */
if (write(fildes, tst_buff, strlen(tst_buff)) != strlen(tst_buff)) {
if (write(fildes, tst_buff, strlen(tst_buff))
!= (int)strlen(tst_buff)) {
tst_brkm(TFAIL, NULL, "write() on %s Failed, errno=%d : %s",
TEMPFILE, errno, strerror(errno));
free(tst_buff);

View File

@ -203,7 +203,7 @@ setup()
j = 0;
for (i = 0; i < szcharbuf; ) {
wrbuf[i++] = rawchars[j++];
if (j >= sizeof(rawchars)) {
if (j >= (int)sizeof(rawchars)) {
j = 0;
}
}

View File

@ -122,7 +122,7 @@ main(int ac, char **av)
/* write the message to the pipe */
if (write(fildes[1], write_buf, strlen(write_buf))
< strlen(write_buf)) {
< (int)strlen(write_buf)) {
tst_brkm(TBROK, cleanup, "write() failed on write "
"to pipe, error:%d", errno);
}
@ -166,7 +166,7 @@ main(int ac, char **av)
/* Read data from read end of pipe */
if (read(fildes[0], read_buf, sizeof(read_buf)) !=
strlen(write_buf)) {
(int)strlen(write_buf)) {
tst_brkm(TFAIL, NULL, "read() failed - "
"error:%d", errno);
exit(1);

View File

@ -199,7 +199,7 @@ setup()
/* Write the buffer data into file */
if (write(fildes, write_buffer, strlen(write_buffer)) != \
strlen(write_buffer)) {
(int)strlen(write_buffer)) {
tst_brkm(TBROK, cleanup,
"write() failed to write buffer data to %s",
TEMP_FILE);

View File

@ -88,7 +88,7 @@ main(int argc, char **argv)
*/
start_time = time(NULL);
for (;;) {
if (times(&buf1) == -1) {
if (times(&buf1) == (clock_t)-1) {
TEST_ERROR_LOG(errno);
tst_resm(TFAIL, "Call to times(2) "
"failed, errno = %d", errno);
@ -98,7 +98,7 @@ main(int argc, char **argv)
break;
}
}
if (times(&buf1) == -1) {
if (times(&buf1) == (clock_t)-1) {
TEST_ERROR_LOG(errno);
tst_resm(TFAIL, "Call to times(2) failed, "
"errno = %d", errno);
@ -145,7 +145,7 @@ main(int argc, char **argv)
*/
start_time = time(NULL);
for (;;) {
if (times(&buf2) == -1) {
if (times(&buf2) == (clock_t)-1) {
tst_resm(TFAIL,
"Call to times "
"failed, "
@ -166,7 +166,7 @@ main(int argc, char **argv)
tst_resm(TFAIL, "Call to times(2) "
"failed in child");
}
if (times(&buf2) == -1) {
if (times(&buf2) == (clock_t)-1) {
TEST_ERROR_LOG(TEST_ERRNO);
tst_resm(TFAIL, "Call to times failed "
"errno = %d", errno);

View File

@ -67,7 +67,7 @@ main(int argc, char **argv)
const char *msg;
struct stat statbuf;
int mskval = 0000;
unsigned mskval = 0000;
int fildes, i;
unsigned low9mode;

View File

@ -87,7 +87,7 @@ int main ()
char buf3[20];
int i;
unsigned i;
strcpy (fnam1, "mmaptest01.1.XXXXXX");
strcpy (fnam2, "mmaptest01.2.XXXXXX");