diff options
| author | 2003-07-13 00:49:54 +0000 | |
|---|---|---|
| committer | 2003-07-13 00:49:54 +0000 | |
| commit | 22487936468d60ee02b3f7ad83506dc3a903cb2e (patch) | |
| tree | ae354dc79c825061d4d33c9aa2cc394b4945efe6 /tools | |
| parent | Updates from 0.10.0 release. (diff) | |
Fix compiler warnings.
git-svn-id: svn://svn.linux1394.org/libraw1394/trunk@109 53a565d1-3bb7-0310-b661-cf11e63c67ab
Diffstat (limited to '')
| -rw-r--r-- | tools/sendiso.c | 23 | ||||
| -rw-r--r-- | tools/testlibraw.c | 6 |
2 files changed, 19 insertions, 10 deletions
diff --git a/tools/sendiso.c b/tools/sendiso.c index 743c83e..8e20cec 100644 --- a/tools/sendiso.c +++ b/tools/sendiso.c @@ -1,9 +1,20 @@ +/* + * libraw1394 - library for raw access to the 1394 bus with the Linux subsystem. + * + * Copyright (C) 1999,2000 Andreas Bombe + * + * This library is licensed under the GNU Lesser General Public License (LGPL), + * version 2.1 or later. See the file COPYING.LIB in the distribution for + * details. + */ + #include <stdlib.h> #include <stdio.h> #include <unistd.h> #include <getopt.h> #include <errno.h> #include <fcntl.h> +#include <string.h> #include "../src/raw1394.h" @@ -13,8 +24,6 @@ char *filename; unsigned long loopcount = 1; unsigned int speed; -unsigned long packetcount; -volatile unsigned int pend_req; void usage_exit(int exitcode) { @@ -126,12 +135,12 @@ void parse_args(int argc, char **argv) } -int dec_int_callback(raw1394handle_t unused, int *counter, int unused_errcode) +static int dec_int_callback(raw1394handle_t unused, void *counter, raw1394_errcode_t unused_errcode) { - (*counter)--; - packetcount++; - return 0; + (*(int *)counter)--; + return 0; } +static int pend_req; #define BUF_SIZE 65536 #define BUF_OVER BUF_SIZE @@ -143,7 +152,7 @@ void send_file_once(raw1394handle_t handle, int file) static char buffer[BUF_SIZE + BUF_OVER]; static struct raw1394_reqhandle rh = { - (req_callback_t)dec_int_callback, + dec_int_callback, &pend_req }; diff --git a/tools/testlibraw.c b/tools/testlibraw.c index 2836945..5f73bd9 100644 --- a/tools/testlibraw.c +++ b/tools/testlibraw.c @@ -21,12 +21,12 @@ #define TESTADDR (CSR_REGISTER_BASE + CSR_CYCLE_TIME) const char not_compatible[] = "\ -This libraw1394 does not work with your version of Linux. You need a different -version that matches your kernel (see kernel help text for the raw1394 option to +This libraw1394 does not work with your version of Linux. You need a different\n\ +version that matches your kernel (see kernel help text for the raw1394 option to\n\ find out which is the correct version).\n"; const char not_loaded[] = "\ -This probably means that you don't have raw1394 support in the kernel or that +This probably means that you don't have raw1394 support in the kernel or that\n\ you haven't loaded the raw1394 module.\n"; quadlet_t buffer; |
