summaryrefslogtreecommitdiff
path: root/pr/tests/mbcs.c
diff options
context:
space:
mode:
Diffstat (limited to 'pr/tests/mbcs.c')
-rw-r--r--pr/tests/mbcs.c26
1 files changed, 13 insertions, 13 deletions
diff --git a/pr/tests/mbcs.c b/pr/tests/mbcs.c
index 50d5dd00..c5760939 100644
--- a/pr/tests/mbcs.c
+++ b/pr/tests/mbcs.c
@@ -10,9 +10,9 @@
**
** where dirName is the directory to be traversed. dirName is required.
**
-** Description:
+** Description:
** mbcs.c tests use of multi-byte characters, as would be passed to
-** NSPR funtions by internationalized applications.
+** NSPR funtions by internationalized applications.
**
** mbcs.c, when run on any single-byte platform, should run correctly.
** In truth, running the mbcs test on a single-byte platform is
@@ -31,11 +31,11 @@
** named such that when represented in the local multi-byte character
** set, one or more characters of the name is longer than a single
** byte.
-**
+**
*/
-#include <plgetopt.h>
-#include <nspr.h>
+#include <plgetopt.h>
+#include <nspr.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -68,7 +68,7 @@ static void TraverseDirectory( unsigned char *dir )
printf("Directory: %s\n", dir );
cwd = PR_OpenDir( dir );
if ( NULL == cwd ) {
- printf("PR_OpenDir() failed on directory: %s, with error: %d, %d\n",
+ printf("PR_OpenDir() failed on directory: %s, with error: %d, %d\n",
dir, PR_GetError(), PR_GetOSError());
exit(1);
}
@@ -76,7 +76,7 @@ static void TraverseDirectory( unsigned char *dir )
sprintf( file, "%s/%s", dir, dirEntry->name );
rc = PR_GetFileInfo( file, &info );
if ( PR_FAILURE == rc ) {
- printf("PR_GetFileInfo() failed on file: %s, with error: %d, %d\n",
+ printf("PR_GetFileInfo() failed on file: %s, with error: %d, %d\n",
dirEntry->name, PR_GetError(), PR_GetOSError());
exit(1);
}
@@ -84,12 +84,12 @@ static void TraverseDirectory( unsigned char *dir )
printf("File: %s \tsize: %ld\n", dirEntry->name, info.size );
fd = PR_Open( file, PR_RDONLY, 0 );
if ( NULL == fd ) {
- printf("PR_Open() failed. Error: %ld, OSError: %ld\n",
+ printf("PR_Open() failed. Error: %ld, OSError: %ld\n",
PR_GetError(), PR_GetOSError());
}
rc = PR_Close( fd );
if ( PR_FAILURE == rc ) {
- printf("PR_Close() failed. Error: %ld, OSError: %ld\n",
+ printf("PR_Close() failed. Error: %ld, OSError: %ld\n",
PR_GetError(), PR_GetOSError());
}
} else if ( PR_FILE_DIRECTORY == info.type ) {
@@ -104,7 +104,7 @@ static void TraverseDirectory( unsigned char *dir )
rc = PR_CloseDir( cwd );
if ( PR_FAILURE == rc ) {
- printf("PR_CloseDir() failed on directory: %s, with error: %d, %d\n",
+ printf("PR_CloseDir() failed on directory: %s, with error: %d, %d\n",
dir, PR_GetError(), PR_GetOSError());
}
@@ -132,8 +132,8 @@ int main(int argc, char **argv)
msgLevel = PR_LOG_DEBUG;
break;
default:
- dirName = strdup(opt->value);
- break;
+ dirName = strdup(opt->value);
+ break;
}
}
PL_DestroyOptState(opt);
@@ -141,7 +141,7 @@ int main(int argc, char **argv)
lm = PR_NewLogModule("Test"); /* Initialize logging */
-
+
if ( dirName == NULL ) {
printf("you gotta specify a directory as an operand!\n");
exit(1);