diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-03 09:43:16 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2011-08-03 09:43:16 +0000 |
commit | 9f1130cc81b12eb86e31275996b8a6bbe7118111 (patch) | |
tree | 14bc2c85a3df74963dc24d3e23e51dbb300a8275 /gcc/ada/adaint.c | |
parent | 47d41b148dd96c17cdf00bf0f7adce779c707ce0 (diff) | |
download | gcc-9f1130cc81b12eb86e31275996b8a6bbe7118111.tar.gz |
2011-08-03 Pascal Obry <obry@adacore.com>
* makeutl.adb: Minor reformatting.
2011-08-03 Vincent Celier <celier@adacore.com>
* fname-uf.adb
(Get_File_Name) If the file cannot be found when there are no config
pragmas file and May_Fail is True, return No_File instead of the file
name, to be consistent.
2011-08-03 Pascal Obry <obry@adacore.com>
* adaint.c (__gnat_is_executable_file_attr): Avoid access
to null pointer.
2011-08-03 Javier Miranda <miranda@adacore.com>
* sem_ch13.adb
(Same_Representation): In VM targets the representation of arrays with
aliased components differs from arrays with non-aliased components.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@177251 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/adaint.c')
-rw-r--r-- | gcc/ada/adaint.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/ada/adaint.c b/gcc/ada/adaint.c index 6845ff08ec1..3d4c50a979c 100644 --- a/gcc/ada/adaint.c +++ b/gcc/ada/adaint.c @@ -2149,7 +2149,8 @@ __gnat_is_executable_file_attr (char* name, struct file_attributes* attr) TCHAR *l, *last = _tcsstr(wname, _T(".exe")); /* look for last .exe */ - while (l = _tcsstr(last+1, _T(".exe"))) last = l; + if (last) + while (l = _tcsstr(last+1, _T(".exe"))) last = l; attr->executable = GetFileAttributes (wname) != INVALID_FILE_ATTRIBUTES && last - wname == (int) (_tcslen (wname) - 4); |