Added check for file not found.
git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk@107 626c5289-ae23-0410-ae9c-e8d60b6d4f22
This commit is contained in:
parent
65a157d425
commit
abaa7efc19
1 changed files with 4 additions and 0 deletions
|
|
@ -402,6 +402,10 @@ int SWIG_main(int argc, char *argv[], Language *l, Documentation *d) {
|
||||||
FILE *f;
|
FILE *f;
|
||||||
int i;
|
int i;
|
||||||
DOH *ds = Swig_include(input_file);
|
DOH *ds = Swig_include(input_file);
|
||||||
|
if (!ds) {
|
||||||
|
Printf(stderr,"Unable to find '%s'\n", input_file);
|
||||||
|
SWIG_exit(1);
|
||||||
|
}
|
||||||
Seek(ds,0,SEEK_END);
|
Seek(ds,0,SEEK_END);
|
||||||
for (i = 0; i < Len(libfiles); i++) {
|
for (i = 0; i < Len(libfiles); i++) {
|
||||||
Printf(ds,"\n%%include \"%s\"\n", Getitem(libfiles,i));
|
Printf(ds,"\n%%include \"%s\"\n", Getitem(libfiles,i));
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue