diff options
| author | Mike Buland <eichlan@xagasoft.com> | 2012-11-05 22:41:51 +0000 |
|---|---|---|
| committer | Mike Buland <eichlan@xagasoft.com> | 2012-11-05 22:41:51 +0000 |
| commit | ec05778d5718a7912e506764d443a78d6a6179e3 (patch) | |
| tree | 78a9a01532180030c095acefc45763f07c14edb8 /src/tests/bzip2.cpp | |
| parent | b20414ac1fe80a71a90601f4cd1767fa7014a9ba (diff) | |
| download | libbu++-ec05778d5718a7912e506764d443a78d6a6179e3.tar.gz libbu++-ec05778d5718a7912e506764d443a78d6a6179e3.tar.bz2 libbu++-ec05778d5718a7912e506764d443a78d6a6179e3.tar.xz libbu++-ec05778d5718a7912e506764d443a78d6a6179e3.zip | |
Converted tabs to spaces with tabconv.
Diffstat (limited to 'src/tests/bzip2.cpp')
| -rw-r--r-- | src/tests/bzip2.cpp | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/src/tests/bzip2.cpp b/src/tests/bzip2.cpp index 1b6fc2f..26bb9bd 100644 --- a/src/tests/bzip2.cpp +++ b/src/tests/bzip2.cpp | |||
| @@ -10,27 +10,27 @@ | |||
| 10 | 10 | ||
| 11 | int main( int argc, char *argv[] ) | 11 | int main( int argc, char *argv[] ) |
| 12 | { | 12 | { |
| 13 | if( argc < 3 ) | 13 | if( argc < 3 ) |
| 14 | { | 14 | { |
| 15 | printf("usage: %s <in> <out>\n", argv[0] ); | 15 | printf("usage: %s <in> <out>\n", argv[0] ); |
| 16 | return -1; | 16 | return -1; |
| 17 | } | 17 | } |
| 18 | 18 | ||
| 19 | char buf[1024]; | 19 | char buf[1024]; |
| 20 | size_t nRead; | 20 | size_t nRead; |
| 21 | 21 | ||
| 22 | Bu::File fin( argv[1], Bu::File::Read ); | 22 | Bu::File fin( argv[1], Bu::File::Read ); |
| 23 | 23 | ||
| 24 | Bu::File f( argv[2], Bu::File::WriteNew ); | 24 | Bu::File f( argv[2], Bu::File::WriteNew ); |
| 25 | Bu::BZip2 bz2( f ); | 25 | Bu::BZip2 bz2( f ); |
| 26 | 26 | ||
| 27 | for(;;) | 27 | for(;;) |
| 28 | { | 28 | { |
| 29 | nRead = fin.read( buf, 1024 ); | 29 | nRead = fin.read( buf, 1024 ); |
| 30 | if( nRead > 0 ) | 30 | if( nRead > 0 ) |
| 31 | bz2.write( buf, nRead ); | 31 | bz2.write( buf, nRead ); |
| 32 | if( fin.isEos() ) | 32 | if( fin.isEos() ) |
| 33 | break; | 33 | break; |
| 34 | } | 34 | } |
| 35 | } | 35 | } |
| 36 | 36 | ||
