[Pkg-privacy-commits] [libgsecuredelete] 72/168: Tighten dependency on valac to 0.11.1 and cleanup the code accordingly
Ulrike Uhlig
u-guest at moszumanska.debian.org
Thu Jul 7 20:06:41 UTC 2016
This is an automated email from the git hooks/post-receive script.
u-guest pushed a commit to branch master
in repository libgsecuredelete.
commit 8bdd4becaf1ccc8bd2af05790b6fad2d24144800
Author: Colomban Wendling <ban at herbesfolles.org>
Date: Fri Apr 29 01:33:06 2011 +0200
Tighten dependency on valac to 0.11.1 and cleanup the code accordingly
Drop a hack used to workaround a valac bug that is now fixed since
0.11.1. Also cleanup a bit the code around.
---
configure.ac | 2 +-
gsecuredelete/async-operation.vala | 35 +++++++++++------------------------
2 files changed, 12 insertions(+), 25 deletions(-)
diff --git a/configure.ac b/configure.ac
index 7a0b5f2..6d94ae0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -27,7 +27,7 @@ AC_SUBST([GSD_LTVERSION])
# Checks for programs.
LT_PREREQ([2.2.0])
LT_INIT
-AM_PROG_VALAC([0.7.8])
+AM_PROG_VALAC([0.11.1])
GSD_PATH_PROG([SRM], [srm], [/usr/bin/srm])
diff --git a/gsecuredelete/async-operation.vala b/gsecuredelete/async-operation.vala
index a82c201..266a1a1 100644
--- a/gsecuredelete/async-operation.vala
+++ b/gsecuredelete/async-operation.vala
@@ -355,9 +355,8 @@ namespace Gsd
uint watch_interval = 100)
throws SpawnError, AsyncOperationError
{
- bool success = false;
- bool busy = false;
- string?[] args;
+ bool success = false;
+ bool busy = false;
lock (this._busy) {
busy = this._busy;
@@ -367,13 +366,12 @@ namespace Gsd
}
return_val_if_fail (! busy, false);
try {
- args = this.do_build_args ();
this.fd_err = -1;
this.fd_out = -1;
this.n_passes = this.get_max_progress ();
this.passes = 0;
success = Process.spawn_async_with_pipes (
- working_directory, args, this.build_environ (),
+ working_directory, this.do_build_args (), this.build_environ (),
spawn_flags | SpawnFlags.DO_NOT_REAP_CHILD, null,
out this.pid, out this.fd_in, out this.fd_out, out this.fd_err
);
@@ -414,11 +412,10 @@ namespace Gsd
out string standard_output)
throws SpawnError, AsyncOperationError
{
- bool success = true;
- bool busy = false;
- string error_output;
- int exit_status;
- string?[] args;
+ bool success = true;
+ bool busy = false;
+ string error_output;
+ int exit_status;
lock (this._busy) {
busy = this._busy;
@@ -426,20 +423,10 @@ namespace Gsd
}
return_val_if_fail (! busy, false);
try {
- args = this.do_build_args ();
- /* FIXME: hack the current Vala lack of check for null-ness of out
- * parameters before using it.
- * It seems to be a planned thing (as of Vala 0.7.7), as juergbi said on
- * irc.gimp.net#vala */
- if (&standard_output != null) {
- Process.spawn_sync (working_directory, args, this.build_environ (),
- spawn_flags, null,
- out standard_output, out error_output, out exit_status);
- } else {
- Process.spawn_sync (working_directory, args, this.build_environ (),
- spawn_flags, null,
- null, out error_output, out exit_status);
- }
+ success = Process.spawn_sync (working_directory, this.do_build_args (),
+ this.build_environ (), spawn_flags, null,
+ out standard_output, out error_output,
+ out exit_status);
if (success) {
string? message = null;
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/libgsecuredelete.git
More information about the Pkg-privacy-commits
mailing list