SHA256
1
0
forked from pool/systemd
systemd/keep-crypt-password-prompt.patch
Stephan Kulow 9fc3254595 Accepting request 238853 from Base:System
- Update of patch 0001-detect-s390-virt.patch (bnc#880438)

- Shut up stupid check scripts crying for not mentioned systemd-mini-rpmlintrc

- Add upstream patchs
  0001-core-use-correct-format-string-for-UIDs.patch
  0002-core-transaction-fix-cycle-break-attempts-outside-tr.patch
  0003-fsck-consider-a-fsck-implementation-linked-to-bin-tr.patch

- Add upstream patch
  0001-units-order-network-online.target-after-network.targ.patch
  to make sure that etwork-online.target follows network.target 

- rules: re-enable dev_id conditionally in persistent rules
  (bnc#884403 and bnc#882714).
  Add 1040-re-enable-dev_id-conditionally-in-persistent-rules.patch 

- Add upstream patches
  0001-vconsole-also-copy-character-maps-not-just-fonts-fro.patch
  0002-core-make-sure-Environment-fields-passed-in-for-tran.patch
  0003-core-You-can-not-put-the-cached-result-of-use_smack-.patch
  0004-cryptsetup-don-t-add-unit-dependency-on-dev-null-dev.patch
  0005-man-fix-path-in-crypttab-5.patch

- Add upstream patch
  1039-udevadm-settle-fixed-return-code-for-empty-queue.patch it
  fixes udevadm settle exit code which may had roken dracut scripts
  (bnc#884271 comment#18)

- Temporary disable patch 1022 (bnc#884271 and bnc#882714).

OBS-URL: https://build.opensuse.org/request/show/238853
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/systemd?expand=0&rev=190
2014-06-30 19:43:27 +00:00

44 lines
1.3 KiB
Diff

--- systemd-210/src/core/manager.c 2014-05-05 11:46:17.700483956 +0200
+++ systemd-210/src/core/manager.c 2014-05-05 13:29:13.296503646 +0200
@@ -152,6 +152,29 @@
}
}
+static int check_for_password_prompt(void) {
+ DIR *d;
+ struct dirent *de;
+
+ if (!(d = opendir("/run/systemd/ask-password"))) {
+
+ if (errno == ENOENT)
+ return 1;
+ log_error("opendir(/run/systemd/ask-password): %m");
+
+ return -errno;
+ }
+
+ while ((de = readdir(d))) {
+ if (startswith(de->d_name, "ask.")) {
+ closedir(d);
+ return 0;
+ }
+ }
+ closedir(d);
+ return 1;
+}
+
static void manager_print_jobs_in_progress(Manager *m) {
static int is_ansi_console = -1;
_cleanup_free_ char *job_of_n = NULL;
@@ -195,6 +217,10 @@
m->jobs_in_progress_iteration++;
+ //don't overwrite the crypt password prompt with job status messages
+ if (check_for_password_prompt() == 0);
+ return 0;
+
if (m->n_running_jobs > 1)
if (asprintf(&job_of_n, "(%u of %u) ", counter, m->n_running_jobs) < 0)
job_of_n = NULL;