diff options
author | H. Peter Anvin <hpa@zytor.com> | 2009-05-29 15:10:31 -0700 |
---|---|---|
committer | H. Peter Anvin <hpa@zytor.com> | 2009-05-29 15:10:31 -0700 |
commit | 28e2781568934b9fe4ebab76d8ebc31f77c0f337 (patch) | |
tree | d74b96f8d494beadeace58ede308a7ca780da435 | |
parent | eaba011132f81281780be9800e26abfae009fede (diff) | |
download | syslinux-28e2781568934b9fe4ebab76d8ebc31f77c0f337.tar.gz syslinux-28e2781568934b9fe4ebab76d8ebc31f77c0f337.tar.xz syslinux-28e2781568934b9fe4ebab76d8ebc31f77c0f337.zip |
Run Nindent on com32/rosh/rosh.h
Automatically reformat com32/rosh/rosh.h 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>
-rw-r--r-- | com32/rosh/rosh.h | 86 |
1 files changed, 44 insertions, 42 deletions
diff --git a/com32/rosh/rosh.h b/com32/rosh/rosh.h index d7296e1a..64b0564c 100644 --- a/com32/rosh/rosh.h +++ b/com32/rosh/rosh.h @@ -28,15 +28,15 @@ #include <stdio.h> #include <stdlib.h> -#include <stdbool.h> /* macro: true false */ -#include <string.h> /* strcpy() strlen() memcpy() strchr() */ +#include <stdbool.h> /* macro: true false */ +#include <string.h> /* strcpy() strlen() memcpy() strchr() */ #include <sys/types.h> -#include <sys/stat.h> /* fstat() */ -#include <fcntl.h> /* open(); open mode macros */ -#include <dirent.h> /* fdopendir() opendir() readdir() closedir() DIR */ -#include <unistd.h> /* getcwd() */ -#include <errno.h> /* errno; error macros */ -#include <netinet/in.h> /* For htonl/ntohl/htons/ntohs */ +#include <sys/stat.h> /* fstat() */ +#include <fcntl.h> /* open(); open mode macros */ +#include <dirent.h> /* fdopendir() opendir() readdir() closedir() DIR */ +#include <unistd.h> /* getcwd() */ +#include <errno.h> /* errno; error macros */ +#include <netinet/in.h> /* For htonl/ntohl/htons/ntohs */ #include <getkey.h> #include <consoles.h> @@ -45,19 +45,19 @@ /* Plus, there seem to be other references for SYSLINUX to __GNUC__ */ #ifndef __GNUC__ #error SYSLINUX (I believe) requires __GNUC__ -#endif /* __GNUC__ */ +#endif /* __GNUC__ */ #ifdef DO_DEBUG #define ROSH_DEBUG(f, ...) printf (f, ## __VA_ARGS__) #ifdef DO_DEBUG2 #define ROSH_DEBUG2(f, ...) printf (f, ## __VA_ARGS__) -#else /* DO_DEBUG2 */ +#else /* DO_DEBUG2 */ #define ROSH_DEBUG2(f, ...) ((void)0) -#endif /* DO_DEBUG2 */ -#else /* DO_DEBUG */ +#endif /* DO_DEBUG2 */ +#else /* DO_DEBUG */ #define ROSH_DEBUG(f, ...) ((void)0) #define ROSH_DEBUG2(f, ...) ((void)0) -#endif /* DO_DEBUG */ +#endif /* DO_DEBUG */ #ifdef __COM32__ #define ROSH_IS_COM32 1 @@ -70,37 +70,39 @@ #define ROSH_IS_COM32 0 static inline char *syslinux_config_file() { - return ""; + return ""; } + static inline int getscreensize(int fd, int *rows, int *cols) { - char *str; - int rv; - *rows = 0; - *cols = 0; - if (rows) { - str = getenv("LINES"); - if (str) { - *rows = atoi(str); - } + char *str; + int rv; + *rows = 0; + *cols = 0; + if (rows) { + str = getenv("LINES"); + if (str) { + *rows = atoi(str); } - if (cols) { - str = getenv("COLUMNS"); - if (str) { - *cols = atoi(str); - } + } + if (cols) { + str = getenv("COLUMNS"); + if (str) { + *cols = atoi(str); } - if (!rows || !cols) - rv = -1; - else if (!*rows || !*cols) - rv = -2; - else - rv = 0; - return rv; + } + if (!rows || !cols) + rv = -1; + else if (!*rows || !*cols) + rv = -2; + else + rv = 0; + return rv; } + #define ROSH_COM32(f, ...) ((void)0) #define syslinux_run_command(f) ((void)0) -#endif /* __COM32__ */ +#endif /* __COM32__ */ #define SEP '/' @@ -117,8 +119,8 @@ static inline int getscreensize(int fd, int *rows, int *cols) #define ROSH_CMD_SZ COMMAND_LINE_SIZE #else #define ROSH_CMD_SZ 2048 -#endif /* COMMAND_LINE_SIZE */ -#endif /* MAX_CMDLINE_LEN */ +#endif /* COMMAND_LINE_SIZE */ +#endif /* MAX_CMDLINE_LEN */ /* Size of path buffer string */ #ifdef PATH_MAX @@ -127,13 +129,13 @@ static inline int getscreensize(int fd, int *rows, int *cols) #define ROSH_PATH_SZ NAME_MAX #else #define ROSH_PATH_SZ 255 -#endif /* NAME_MAX */ +#endif /* NAME_MAX */ const char rosh_help_str1[] = -"Commands: ? cat cd cfg dir exit help less ls man more pwd run quit ver"; + "Commands: ? cat cd cfg dir exit help less ls man more pwd run quit ver"; const char rosh_help_str2[] = -"Commands: (some 1-letter abreviations also allowed)\n\ + "Commands: (some 1-letter abreviations also allowed)\n\ h HELP\n ALSO ? help man\n\ cat Concatenate file to console\n cat <file>\n\ cd Change to directory <dir>\n cd <dir>\n\ @@ -145,4 +147,4 @@ const char rosh_help_str2[] = run Run a program/kernel with options\n\ exit Exit to previous environment\n ALSO quit"; -#endif /* Not ROSH_H */ +#endif /* Not ROSH_H */ |