Fine tune codepeer settings.
Code clean ups: address some codepeer messages either by improving the code
or making the code more explicit to avoid false positives.
Change-Id: I2abd61236b5ccd1b9b4d9dc9b8316b7f442e9862
A Monitor_Command (for an external process) is wrapped inside a
Scheduled_Command (for the task manager). When the scheduled task
is freed, the monitor command is also freed, but it has a reference
to the scheduled command (used to print a message on the console).
This results in access to freed memory. Remove this internal pointer,
and now pass the low-level command explicitly to the various output
filters (they can still access the scheduled command via a new
Get_Scheduled_Command function in the kernel)
(Next): when moving to the next command in a command list, we should
not free the first command before we have removed it from the list.
Otherwise, the task manager will find that the command we are freeing
belonged to the queue and will try to execute the next command (thus
a nested call to Next, which also results in access to dangling
memory).
(Free): renamed to Primitive_Free, for commands, to make sure the code
is not calling this directly. This fixes various cases where Ref/Unref
was not working properly for commands.
(Execute_Incremental): fix case where we could report a Queue_Changed
event on the wrong queue.
(Active_Incremental, Passive_Incremental): in case of exception, we could
be left in a state where the task manager is not running, but GPS believes
it is.
(GPS.Kernel.Timeout): remove the timeout loop in this package, since the
task manager already has one. This is more efficient, and clarifies the
code (avoids reentrency in some cases). Make sure Exit_Cb is only run
once.
OC14-005
Change-Id: I9972f937d21388e4ba5115c2773d09950a4c567a
This package was obsolete and replaced with GNATCOLL.Traces
Exceptions are now sent to "<name>.EXCEPTIONS" streams, and are
always displayed in the testsuite.
Remove a number of exception handlers in gtk+ callbacks, which were
no longer necessary since GtkAda has its own exception handlers.
M910-019
git-svn-id: svn+ssh://svn.eu.adacore.com/Dev/trunk/gps@215445 936e1b1b-40f2-da11-902a-00137254ae57
(Set_Controls): New profile, returns the created command.
(Unset_Controls): Works directly on the controls command.
* commands-controls.ads:
(Set_Controls): New profile, returns the created command.
(Unset_Controls): Works directly on the controls command.
* commands.adb:
Use Ada containers.
Remove useless subprograms.
* commands.ads:
Remove use of Generic_List and String_List_Utils.
Instead, use Ada.Strings.Unbounded and Ada.Containers.Doubly_Linked_List.
Rename "Command_Queues" package to "Command_Lists, for clarity.
Remove irrelevant comments.
(Launch_Synchronous_Generic): Remove confusing interface.
* commands-interactive.adb:
(Launch_Synchronous_Interactive): Remove, no longer needed.
* commands-interactive.ads:
(Launch_Synchronous_Interactive): Remove, no longer needed.
* gps-kernel-task_manager.ads:
Remove useless 'use'.
* gps-kernel-timeout.adb:
(Execute_Monitor): Remove, not needed.
(Launch_Process): Call Launch_Synchronous API, since Execute_Monitor only
does something that the regular Execute command does.
* gps-kernel.adb:
Use new container for command lists.
* gps-kernel.ads:
Use new container for commands list.
* task_manager-gui.adb:
Adapt to the fact that we are using an Ada Container for the commands lists.
* task_manager-shell.adb:
(Task_Command_Handler): Adapt to new implementation of command lists.
* task_manager.adb:
Adapt to new implementation of command lists.
* task_manager.ads:
Adapt to new implementation of command lists.
* socket_module.adb:
Adapt to new implementation of command lists.
* src_editor_buffer-debug.adb:
(Buffer_Cmds): Adapt to new implementation of command lists.
* src_editor_buffer.adb:
Store a pointer to the command that changes the state of the undo/redo buttons.
This is cleaner than browsing through the list of 'queue change' actions until
we find the right command.
* src_editor_buffer.ads:
Store a pointer to the command that controls the state of the undo/redo
buttons.
For J709-005.
git-svn-id: svn+ssh://svn.eu.adacore.com/Dev/trunk/gps@162466 936e1b1b-40f2-da11-902a-00137254ae57
gnatcoll_shared.gpr
This is for convenience when working with multiple branches in git:
by changing the value (in a single place) on each branch, we can keep
the build tree for each branch, and avoid extra recompilation when
changing branches. For instance, one can set Object_Dir and Library_Dir
to the following value in gnatcoll_shared.gpr (not checked in):
for Object_Dir use "obj/" & External ("GIT_BRANCH", "");
for Library_Dir use "lib/" & External ("GIT_BRANCH", "");
provided the environment variable GIT_BRANCH is set automatically every
time you change the branch (that's under control of the shell)
git-svn-id: svn+ssh://svn.eu.adacore.com/Dev/trunk/gps@160904 936e1b1b-40f2-da11-902a-00137254ae57