This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

committed: ada update


Tested on x86-linux.

2003-10-22  Arnaud Charlet  <charlet@act-europe.fr>

	* Makefile.in: Disable build of gnatpsta. PR ada/10110.
	* cstreams.c (__gnat_full_name): Minor improvements and clean up
	of previous change.

--
Index: cstreams.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/ada/cstreams.c,v
retrieving revision 1.8
diff -u -c -3 -p -r1.8 cstreams.c
*** cstreams.c	22 Oct 2003 11:34:08 -0000	1.8
--- cstreams.c	22 Oct 2003 15:08:03 -0000
*************** int    __gnat_constant_seek_end = SEEK_E
*** 140,176 ****
  int    __gnat_constant_seek_set = SEEK_SET;
  
  FILE *
! __gnat_constant_stderr ()
  {
    return stderr;
  }
  
  FILE *
! __gnat_constant_stdin ()
  {
    return stdin;
  }
  
  FILE *
! __gnat_constant_stdout ()
  {
    return stdout;
  }
  
  char *
! __gnat_full_name (nam, buffer)
!      char *nam;
!      char *buffer;
  {
  #if defined(__EMX__) || defined (__MINGW32__)
-   char *p;
- 
    /* If this is a device file return it as is; under Windows NT and
       OS/2 a device file end with ":".  */
    if (nam[strlen (nam) - 1] == ':')
      strcpy (buffer, nam);
    else
      {
        _fullpath (buffer, nam, __gnat_max_path_len);
  
        for (p = buffer; *p; p++)
--- 140,174 ----
  int    __gnat_constant_seek_set = SEEK_SET;
  
  FILE *
! __gnat_constant_stderr (void)
  {
    return stderr;
  }
  
  FILE *
! __gnat_constant_stdin (void)
  {
    return stdin;
  }
  
  FILE *
! __gnat_constant_stdout (void)
  {
    return stdout;
  }
  
  char *
! __gnat_full_name (char *nam, char *buffer)
  {
  #if defined(__EMX__) || defined (__MINGW32__)
    /* If this is a device file return it as is; under Windows NT and
       OS/2 a device file end with ":".  */
    if (nam[strlen (nam) - 1] == ':')
      strcpy (buffer, nam);
    else
      {
+       char *p;
+ 
        _fullpath (buffer, nam, __gnat_max_path_len);
  
        for (p = buffer; *p; p++)
*************** __gnat_full_name (nam, buffer)
*** 189,195 ****
       getcwd approach instead. */
    realpath (nam, buffer);
  
-   return buffer;
  #elif defined (VMS)
    strncpy (buffer, __gnat_to_canonical_file_spec (nam), __gnat_max_path_len);
  
--- 187,192 ----
*************** __gnat_full_name (nam, buffer)
*** 207,220 ****
        strncpy (buffer, __gnat_to_host_file_spec (buffer), __gnat_max_path_len);
      }
  
-   return buffer;
- 
  #else
-   char *p;
- 
    if (nam[0] != '/')
      {
!       p = getcwd (buffer, __gnat_max_path_len);
        if (p == 0)
  	{
  	  buffer[0] = '\0';
--- 204,214 ----
        strncpy (buffer, __gnat_to_host_file_spec (buffer), __gnat_max_path_len);
      }
  
  #else
    if (nam[0] != '/')
      {
!       char *p = getcwd (buffer, __gnat_max_path_len);
! 
        if (p == 0)
  	{
  	  buffer[0] = '\0';
*************** __gnat_full_name (nam, buffer)
*** 230,236 ****
      }
    else
      strcpy (buffer, nam);
  
    return buffer;
- #endif
  }
--- 224,230 ----
      }
    else
      strcpy (buffer, nam);
+ #endif
  
    return buffer;
  }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]