diff options
author | Jim Meyering <jim@meyering.net> | 2000-11-24 21:41:38 +0000 |
---|---|---|
committer | Jim Meyering <jim@meyering.net> | 2000-11-24 21:41:38 +0000 |
commit | 3d6852f7fa85d83ad085d90587a4dc3015e5b963 (patch) | |
tree | d6e94bd0138cc56fc0731883fa329a5f8e23c882 /src | |
parent | dd82647d0c69a1f3f14b5455b06f4b3a968144d3 (diff) | |
download | coreutils-3d6852f7fa85d83ad085d90587a4dc3015e5b963.tar.xz |
Declare a pointer parameters to be `const' as appropriate.
Diffstat (limited to 'src')
-rw-r--r-- | src/dd.c | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -755,7 +755,7 @@ buggy_lseek_support (int fdesc) nonzero. */ static void -skip (int fdesc, char *file, uintmax_t records, size_t blocksize, +skip (int fdesc, char const *file, uintmax_t records, size_t blocksize, unsigned char *buf) { off_t o; @@ -791,10 +791,10 @@ skip (int fdesc, char *file, uintmax_t records, size_t blocksize, /* Copy NREAD bytes of BUF, with no conversions. */ static void -copy_simple (unsigned char *buf, int nread) +copy_simple (unsigned char const *buf, int nread) { int nfree; /* Number of unused bytes in `obuf'. */ - unsigned char *start = buf; /* First uncopied char in BUF. */ + const unsigned char *start = buf; /* First uncopied char in BUF. */ do { @@ -818,7 +818,7 @@ copy_simple (unsigned char *buf, int nread) replacing the newline with trailing spaces). */ static void -copy_with_block (unsigned char *buf, size_t nread) +copy_with_block (unsigned char const *buf, size_t nread) { size_t i; @@ -850,7 +850,7 @@ copy_with_block (unsigned char *buf, size_t nread) with a newline). */ static void -copy_with_unblock (unsigned char *buf, size_t nread) +copy_with_unblock (unsigned char const *buf, size_t nread) { size_t i; unsigned char c; @@ -944,8 +944,8 @@ dd_copy (void) 0+0 records out */ - skip (STDOUT_FILENO, output_file, seek_record, output_blocksize, - obuf); + skip (STDOUT_FILENO, output_file, seek_record, output_blocksize, + obuf); } if (max_records == 0) |