aboutsummaryrefslogtreecommitdiffstats
path: root/com32/samples
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2009-05-29 15:10:31 -0700
committerH. Peter Anvin <hpa@zytor.com>2009-05-29 15:10:31 -0700
commit746b8fc13253278810a0bc33a252884e227cf053 (patch)
tree9dd1ba73ca45798bf6ae6d0a2a933fd00050eb68 /com32/samples
parentd80d9c74bfe44b5cc864529b7100d25083a9d4b3 (diff)
downloadsyslinux-746b8fc13253278810a0bc33a252884e227cf053.tar.gz
syslinux-746b8fc13253278810a0bc33a252884e227cf053.tar.xz
syslinux-746b8fc13253278810a0bc33a252884e227cf053.zip
Run Nindent on com32/samples/cat.c
Automatically reformat com32/samples/cat.c using Nindent. Do this for all files except HDT, gPXE and externally maintained libraries (zlib, tinyjpeg, libpng). Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Diffstat (limited to 'com32/samples')
-rw-r--r--com32/samples/cat.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/com32/samples/cat.c b/com32/samples/cat.c
index 277427ff..16380b0e 100644
--- a/com32/samples/cat.c
+++ b/com32/samples/cat.c
@@ -4,28 +4,28 @@
int main(int argc, char *argv[])
{
- FILE *f;
- int ch;
- int i;
+ FILE *f;
+ int ch;
+ int i;
- openconsole(&dev_stdcon_r, &dev_stdcon_w);
+ openconsole(&dev_stdcon_r, &dev_stdcon_w);
- printf("argv = %p\n", argv);
- for ( i = 0 ; i <= argc ; i++ )
- printf("argv[%d] = %p = \"%s\"\n", i, argv[i], argv[i]);
+ printf("argv = %p\n", argv);
+ for (i = 0; i <= argc; i++)
+ printf("argv[%d] = %p = \"%s\"\n", i, argv[i], argv[i]);
- if ( argc < 2 ) {
- fprintf(stderr, "Missing file name!\n");
- exit(1);
- }
+ if (argc < 2) {
+ fprintf(stderr, "Missing file name!\n");
+ exit(1);
+ }
- printf("File = %s\n", argv[1]);
+ printf("File = %s\n", argv[1]);
- f = fopen(argv[1], "r");
- while ( (ch = getc(f)) != EOF )
- putchar(ch);
+ f = fopen(argv[1], "r");
+ while ((ch = getc(f)) != EOF)
+ putchar(ch);
- fclose(f);
+ fclose(f);
- return 0;
+ return 0;
}