[PATCH] cosmetic fixes for example programs in Documentation/cdrom/sbpcd

This patch makes a few minor changes to the example programs in
Documentation/cdrom/sbpcd to kill off some warnings and build failures.

Signed-off-by: Jesper Juhl <juhl-lkml@dif.dk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

authored by Jesper Juhl and committed by Linus Torvalds a1ae13a4 8c0e33c1

+10 -6
+10 -6
Documentation/cdrom/sbpcd
··· 419 419 */ 420 420 #include <stdio.h> 421 421 #include <sys/ioctl.h> 422 + #include <sys/types.h> 422 423 #include <linux/cdrom.h> 423 424 424 425 static struct cdrom_tochdr hdr; ··· 430 429 static int i, j, limit, track, err; 431 430 static char filename[32]; 432 431 433 - main(int argc, char *argv[]) 432 + int main(int argc, char *argv[]) 434 433 { 435 434 /* 436 435 * open /dev/cdrom ··· 517 516 } 518 517 arg.addr.lba++; 519 518 } 519 + return 0; 520 520 } 521 521 /*===================== end program ========================================*/ 522 522 ··· 566 564 #include <stdio.h> 567 565 #include <malloc.h> 568 566 #include <sys/ioctl.h> 567 + #include <sys/types.h> 569 568 #include <linux/cdrom.h> 570 569 571 570 #ifdef AZT_PRIVATE_IOCTLS 572 571 #include <linux/../../drivers/cdrom/aztcd.h> 573 - #endif AZT_PRIVATE_IOCTLS 572 + #endif /* AZT_PRIVATE_IOCTLS */ 574 573 #ifdef SBP_PRIVATE_IOCTLS 575 574 #include <linux/../../drivers/cdrom/sbpcd.h> 576 575 #include <linux/fs.h> 577 - #endif SBP_PRIVATE_IOCTLS 576 + #endif /* SBP_PRIVATE_IOCTLS */ 578 577 579 578 struct cdrom_tochdr hdr; 580 579 struct cdrom_tochdr tocHdr; ··· 593 590 struct cdrom_msf msf; 594 591 unsigned char buf[CD_FRAMESIZE_RAW]; 595 592 } azt; 596 - #endif AZT_PRIVATE_IOCTLS 593 + #endif /* AZT_PRIVATE_IOCTLS */ 597 594 int i, i1, i2, i3, j, k; 598 595 unsigned char sequence=0; 599 596 unsigned char command[80]; ··· 741 738 } 742 739 } 743 740 744 - main(int argc, char *argv[]) 741 + int main(int argc, char *argv[]) 745 742 { 746 743 printf("\nTesting tool for a CDROM driver's audio functions V0.1\n"); 747 744 printf("(C) 1995 Eberhard Moenkeberg <emoenke@gwdg.de>\n"); ··· 1049 1046 rc=ioctl(drive,CDROMAUDIOBUFSIZ,j); 1050 1047 printf("%d frames granted.\n",rc); 1051 1048 break; 1052 - #endif SBP_PRIVATE_IOCTLS 1049 + #endif /* SBP_PRIVATE_IOCTLS */ 1053 1050 default: 1054 1051 printf("unknown command: \"%s\".\n",command); 1055 1052 break; 1056 1053 } 1057 1054 } 1055 + return 0; 1058 1056 } 1059 1057 /*==========================================================================*/ 1060 1058