minor fixes from last checkin
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@11002 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
da0b517a7f
commit
1b485a7ad2
1 changed files with 4 additions and 4 deletions
|
|
@ -943,7 +943,7 @@ int SWIG_main(int argc, char *argv[], Language *l) {
|
||||||
// If the user has requested to check out a file, handle that
|
// If the user has requested to check out a file, handle that
|
||||||
if (checkout) {
|
if (checkout) {
|
||||||
DOH *s;
|
DOH *s;
|
||||||
String *outfile = Char(input_file);
|
char *outfile = Char(input_file);
|
||||||
if (outfile_name)
|
if (outfile_name)
|
||||||
outfile = outfile_name;
|
outfile = outfile_name;
|
||||||
|
|
||||||
|
|
@ -952,12 +952,12 @@ int SWIG_main(int argc, char *argv[], Language *l) {
|
||||||
|
|
||||||
s = Swig_include(input_file);
|
s = Swig_include(input_file);
|
||||||
if (!s) {
|
if (!s) {
|
||||||
fprintf(stderr, "Unable to locate '%s' in the SWIG library.\n", input_file);
|
Printf(stderr, "Unable to locate '%s' in the SWIG library.\n", input_file);
|
||||||
} else {
|
} else {
|
||||||
FILE *f = Swig_include_open(outfile);
|
FILE *f = Swig_include_open(outfile);
|
||||||
if (f) {
|
if (f) {
|
||||||
fclose(f);
|
fclose(f);
|
||||||
fprintf(stderr, "File '%s' already exists. Checkout aborted.\n", outfile);
|
Printf(stderr, "File '%s' already exists. Checkout aborted.\n", outfile);
|
||||||
} else {
|
} else {
|
||||||
File *f_outfile = NewFile(outfile, "w", SWIG_output_files());
|
File *f_outfile = NewFile(outfile, "w", SWIG_output_files());
|
||||||
if (!f_outfile) {
|
if (!f_outfile) {
|
||||||
|
|
@ -965,7 +965,7 @@ int SWIG_main(int argc, char *argv[], Language *l) {
|
||||||
SWIG_exit(EXIT_FAILURE);
|
SWIG_exit(EXIT_FAILURE);
|
||||||
} else {
|
} else {
|
||||||
if (Verbose)
|
if (Verbose)
|
||||||
fprintf(stdout, "'%s' checked out from the SWIG library.\n", outfile);
|
Printf(stdout, "'%s' checked out from the SWIG library.\n", outfile);
|
||||||
Printv(f_outfile, s, NIL);
|
Printv(f_outfile, s, NIL);
|
||||||
Close(f_outfile);
|
Close(f_outfile);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue