* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- * must display the following acknowledgement:
- * This product includes software developed by the University of
- * California, Berkeley and its contributors.
- * 4. Neither the name of the University nor the names of its contributors
+ * 3. Neither the name of the University nor the names of its contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
#ifndef lint
static const char rcsid[] =
- "$Id: rmt.c,v 1.22 2003/01/10 14:42:51 stelian Exp $";
+ "$Id: rmt.c,v 1.24 2003/03/30 15:40:40 stelian Exp $";
#endif /* not linux */
/*
int
main(int argc, char *argv[])
{
- int rval = 0;
+ OFF_T rval = 0;
char c;
int n, i, cc, oflags;
unsigned long block = 0;
rval = read(tape, record, n);
if (rval < 0)
goto ioerror;
- (void)sprintf(resp, "A%d\n", rval);
+ (void)sprintf(resp, "A%lld\n", (long long)rval);
(void)write(1, resp, strlen(resp));
(void)write(1, record, rval);
block += n >> 10;
if (ioctl(tape, MTIOCGET, (char *)&mtget) < 0)
goto ioerror;
rval = sizeof (mtget);
- (void)sprintf(resp, "A%d\n", rval);
+ (void)sprintf(resp, "A%lld\n", (long long)rval);
(void)write(1, resp, strlen(resp));
(void)write(1, (char *)&mtget, sizeof (mtget));
goto top;
exit(3);
}
respond:
- DEBUG1("rmtd: A %d\n", rval);
- (void)sprintf(resp, "A%d\n", rval);
+ DEBUG1("rmtd: A %lld\n", (long long)rval);
+ (void)sprintf(resp, "A%lld\n", (long long)rval);
(void)write(1, resp, strlen(resp));
goto top;
ioerror: