Package: plymouth
Version: 0.8.3-20.1
Severity: wishlist
Tags: patch
User: ubuntu-de...@lists.ubuntu.com
Usertags: origin-ubuntu quantal ubuntu-patch

Hi Daniel,

Could you please consider including the attached patch, which has been
committed upstream in plymouth git?  It introduces a new API which is fairly
crucial for mountall interactions with plymouth, which is itself a
prerequisite for having a modern upstart in Debian.

Thanks for considering the patch.

-- 
Steve Langasek                   Give me a lever long enough and a Free OS
Debian Developer                   to set it on, and I can move the world.
Ubuntu Developer                                    http://www.debian.org/
slanga...@ubuntu.com                                     vor...@debian.org
diff -Nru plymouth-0.8.3/debian/patches/08-client-add-new-flush-api.patch plymouth-0.8.3/debian/patches/08-client-add-new-flush-api.patch
--- plymouth-0.8.3/debian/patches/08-client-add-new-flush-api.patch	1969-12-31 16:00:00.000000000 -0800
+++ plymouth-0.8.3/debian/patches/08-client-add-new-flush-api.patch	2012-05-12 01:14:03.000000000 -0700
@@ -0,0 +1,73 @@
+From e274cda1eee35730faa47a10198c0740e635c724 Mon Sep 17 00:00:00 2001
+From: Steve Langasek <steve.langa...@canonical.com>
+Date: Fri, 11 May 2012 00:38:17 -0700
+Subject: [PATCH] client: add new flush api
+
+In some cases, clients may need a way to ensure that all queued
+messages have been flushed and are sent to the daemon
+(before, for instance, exiting).
+
+This commit adds an API to block until the outgoing request queue is
+empty.
+---
+ configure.ac                 |    4 ++--
+ src/client/ply-boot-client.c |   11 +++++++++++
+ src/client/ply-boot-client.h |    1 +
+ 3 files changed, 14 insertions(+), 2 deletions(-)
+
+Index: plymouth-0.8.3/configure.ac
+===================================================================
+--- plymouth-0.8.3.orig/configure.ac
++++ plymouth-0.8.3/configure.ac
+@@ -18,7 +18,7 @@
+ LT_INIT
+ 
+ ## increment if the interface has additions, changes, removals.
+-LT_CURRENT=2
++LT_CURRENT=3
+ 
+ ## increment any time the source changes; set to
+ ##  0 if you increment CURRENT
+@@ -27,7 +27,7 @@
+ ## increment if any interfaces have been added; set to 0
+ ## if any interfaces have been changed or removed. removal has
+ ## precedence over adding, so set to 0 if both happened.
+-LT_AGE=0
++LT_AGE=1
+ 
+ AC_SUBST(LT_CURRENT)
+ AC_SUBST(LT_REVISION)
+Index: plymouth-0.8.3/src/client/ply-boot-client.c
+===================================================================
+--- plymouth-0.8.3.orig/src/client/ply-boot-client.c
++++ plymouth-0.8.3/src/client/ply-boot-client.c
+@@ -743,6 +743,17 @@
+ }
+ 
+ void
++ply_boot_client_flush (ply_boot_client_t *client)
++{
++  assert (client != NULL);
++
++  while (ply_list_get_length (client->requests_to_send) > 0)
++    {
++      ply_event_loop_process_pending_events (client->loop);
++    }
++}
++
++void
+ ply_boot_client_disconnect (ply_boot_client_t *client)
+ {
+   assert (client != NULL);
+Index: plymouth-0.8.3/src/client/ply-boot-client.h
+===================================================================
+--- plymouth-0.8.3.orig/src/client/ply-boot-client.h
++++ plymouth-0.8.3/src/client/ply-boot-client.h
+@@ -129,6 +129,7 @@
+                                                ply_boot_client_response_handler_t  handler,
+                                                ply_boot_client_response_handler_t  failed_handler,
+                                                void                               *user_data);
++void ply_boot_client_flush (ply_boot_client_t *client);
+ void ply_boot_client_disconnect (ply_boot_client_t *client);
+ void ply_boot_client_attach_to_event_loop (ply_boot_client_t *client,
+                                            ply_event_loop_t  *loop);
diff -Nru plymouth-0.8.3/debian/patches/series plymouth-0.8.3/debian/patches/series
--- plymouth-0.8.3/debian/patches/series	2011-09-08 06:36:47.000000000 -0700
+++ plymouth-0.8.3/debian/patches/series	2012-05-12 01:13:58.000000000 -0700
@@ -5,3 +5,4 @@
 05-default-theme.patch
 06-tty.patch
 07-return-code.patch
+08-client-add-new-flush-api.patch

Reply via email to