Commit Graph

43 Commits

Author SHA1 Message Date
Nicolas Setton
957642e2e3 (glib): complete tag to address compiler warning
Add the information that Process is tagged, to avoid
 "warning: applying 'Class to an untagged incomplete type
  is an obsolescent feature (RM J.11)"
2021-01-17 14:47:52 +00:00
Maxim Reznik
03cac0cd15 Add GitHub Action 2020-11-20 12:19:05 +02:00
Maxim Reznik
56f6791d0f Update README.md. Add Makefile.
Update copyright headers.
2020-11-20 12:18:57 +02:00
Vadim Godunko
9b5dd70aa8 TA14-018 Rewrite pipe initialization code for interprocess communication
Each pipe has unique name now. Each pipe can have only one instance.
Attempt to use another pipe name on case of failure.

Wait to complete of pipe initialization.
2020-11-20 11:25:36 +02:00
Maxim Reznik
4f404a5ef7 T803-008 Add a test for Process API
that calls Write_Standard_Input before and after subprocess run.
1.0.0
2020-11-20 11:25:36 +02:00
Maxim Reznik
f85f41cdba T803-008 Turn Process API example into a test 2020-11-20 11:25:36 +02:00
Maxim Reznik
eceffa3f9d Fix typo in expand array code 2020-11-20 11:25:36 +02:00
Vadim Godunko
88952066aa T710-023 Fix size of data to be submitted.
Use constant for buffer size.
2020-11-20 11:25:36 +02:00
Vadim Godunko
9d816839cb T626-018 Change in Process API
We change behavior of the Write_Standard_Input when only
a part of the data buffer is written. In this case the
Standard_Input_Available will be called. Note there is a
difference with Standard_Output_Available in the same
situation.
2020-11-20 11:25:36 +02:00
Andry Ogorodnik
fc8346c329 T519-034 Fix Append_Escaped_String 2020-11-20 11:25:36 +02:00
Anthony Leonardo Gracio
cd5c0e15f2 T406-014: Fix compilation errors in spawn-process_glib.adb 2020-11-20 11:25:36 +02:00
Maxim Reznik
893f6d1879 T406-014 Fix compilation on new GNAT Pro compiler.
It requires type use visibility for 'in' and 'not in' operations.
2020-11-20 11:25:36 +02:00
Maxim Reznik
87ff27d6c7 T318-072 We still compile ALS on RHES 5
where there is no O_CLOEXEC nor pipe2. This fix is to avoid
compilation error there.
2020-11-20 11:25:36 +02:00
Maxim Reznik
ea0f133e8f T318-072 Port Spawn Process API to Darwin/Mac OS X 2020-11-20 11:25:36 +02:00
Vadim Godunko
e2224a559d T117-039 Escape command line arguments when necessary 2020-11-20 11:25:36 +02:00
Pierre-Marie de Rodat
5d6d050e5f gnat/spawn.gpr: add a switch to disable warning-as-errors
TN: T102-006
2020-11-20 11:25:36 +02:00
Nicolas Setton
e8f16396d8 S926-040 Prevent exceptions from propagating to the Gtk main loop
Ada exceptions propagating to the Gtk+ main loop is generally
unwanted and causes a crash of the application - prevent this by
default by calling a handler that can be overridden.
2020-11-20 11:25:36 +02:00
Maxim Reznik
d12cb10943 S709-021 Restart I/O operation on EINTR.
As discussed in the ticket it could happen sometimes.
2020-11-20 11:25:36 +02:00
Pierre-Marie de Rodat
965e18678a Consistently use short-circuit boolean operators
As per AdaCore's coding style, and to avoid logic errors: programmers
usually rely on Y not to be evaluated when X is False in (X AND Y),
likewise for OR operations.

TN: S704-013
2020-11-20 11:25:36 +02:00
Vadim Godunko
3f72fa18ee S617-013 Remove IO waiting callbacks on stop of the process.
To prevent access to potentially released memory later from these callbacks.
2020-11-20 11:25:36 +02:00
Vadim Godunko
54df0fc929 S515-039 Use correct stream. 2020-11-20 11:25:36 +02:00
Vadim Godunko
ecbebb56d0 S506-022 Fix GPS on exit crash on Windows. 2020-11-20 11:25:36 +02:00
Vadim Godunko
7caf1f2478 Don't raise exception during finalization...
...to prevent finalization issues in GPS for now.
2020-11-20 11:25:36 +02:00
Maxim Reznik
48f954e1e9 S125-009 Add Search_Path function to Spawn API
to search full path of executable. We've considered to let Start
subprogram find full path, but this could be wrong if PATH environment
variable differs in child process environments. So client should find
full path in correct environment with new function Search_Path and pass
full path to Set_Program.
2020-11-20 11:25:36 +02:00
Maxim Reznik
8d3d818e11 S327-016 Fix build failure on Windows
This patch fixes build of Process API (Glib based implementation) on Windows.
When spawn related bindong for Glib was moved to GtkAda repository this file
wasn't fixed. Fix includes some renames to match code in GtkAda that is now
auto generated.
2020-11-20 11:25:36 +02:00