diff -ur rcd-2.4.9-old/src/you-module/rc-you-package.c rcd-2.4.9/src/you-module/rc-you-package.c --- rcd-2.4.9-old/src/you-module/rc-you-package.c 2004-06-10 04:15:43.000000000 -0500 +++ rcd-2.4.9/src/you-module/rc-you-package.c 2006-06-29 11:35:32.000000000 -0500 @@ -41,15 +41,9 @@ if (package->base_package) rc_you_file_unref (package->base_package); -#if 0 - /* This is not used righ now (and probably never will) */ if (package->patch_rpm_based_on) { - g_slist_foreach (package->patch_rpm_based_on, - G_FUNC (g_free), - NULL); - g_slist_free (package->patch_rpm_based_on); + g_strfreev (package->patch_rpm_based_on); } -#endif if (package->patch_rpm) rc_you_file_unref (package->patch_rpm); Only in rcd-2.4.9/src/you-module: rc-you-package.c~ diff -ur rcd-2.4.9-old/src/you-module/rc-you-package.h rcd-2.4.9/src/you-module/rc-you-package.h --- rcd-2.4.9-old/src/you-module/rc-you-package.h 2004-06-10 04:15:43.000000000 -0500 +++ rcd-2.4.9/src/you-module/rc-you-package.h 2006-06-29 11:54:05.000000000 -0500 @@ -39,7 +39,7 @@ struct _RCYouPackage { gint refs; RCYouFile *base_package; - GSList *patch_rpm_based_on; + gchar **patch_rpm_based_on; RCYouFile *patch_rpm; guint32 patch_rpm_size; guint32 patch_rpm_dlsize; Only in rcd-2.4.9/src/you-module: rc-you-package.h~ diff -ur rcd-2.4.9-old/src/you-module/rc-you-patch.h rcd-2.4.9/src/you-module/rc-you-patch.h --- rcd-2.4.9-old/src/you-module/rc-you-patch.h 2005-01-13 09:01:31.000000000 -0600 +++ rcd-2.4.9/src/you-module/rc-you-patch.h 2006-06-29 11:57:13.000000000 -0500 @@ -68,6 +68,7 @@ guint installed : 1; guint install_only : 1; + gint applies; }; RCYouPatch *rc_you_patch_new (void); Only in rcd-2.4.9/src/you-module: rc-you-patch.h~ diff -ur rcd-2.4.9-old/src/you-module/rc-you-query.h rcd-2.4.9/src/you-module/rc-you-query.h --- rcd-2.4.9-old/src/you-module/rc-you-query.h 2004-06-11 09:21:36.000000000 -0500 +++ rcd-2.4.9/src/you-module/rc-you-query.h 2006-06-29 11:34:42.000000000 -0500 @@ -34,5 +34,4 @@ RCDQueryPart *query_parts, RCPatchFn matching_patch_cb, gpointer user_data); - #endif /* __RC_YOU_QUERY_H__ */ diff -ur rcd-2.4.9-old/src/you-module/rc-you-transaction.c rcd-2.4.9/src/you-module/rc-you-transaction.c --- rcd-2.4.9-old/src/you-module/rc-you-transaction.c 2005-10-11 19:11:47.000000000 -0500 +++ rcd-2.4.9/src/you-module/rc-you-transaction.c 2006-06-29 12:05:55.000000000 -0500 @@ -268,6 +268,26 @@ transaction->name = g_strdup (name); } +gint +rc_you_patch_compare (gconstpointer a, gconstpointer b) +{ + gint retval; + const RCYouPatch *p0 = (const RCYouPatch *) a; + const RCYouPatch *p1 = (const RCYouPatch *) b; + + gint n0 = atoi (p0->spec.version); + gint n1 = atoi (p1->spec.version); + + if (n0 == n1) + retval = 0; + else if (n0 < n1) + retval = -1; + else + retval = 1; + + return retval; +} + void rc_you_transaction_set_patches (RCYouTransaction *transaction, RCYouPatchSList *patches) @@ -293,8 +313,9 @@ rc_package_spec_get_name (RC_PACKAGE_SPEC (patch))); /* ok, accept */ - transaction->patches = g_slist_prepend (transaction->patches, - rc_you_patch_ref (patch)); + transaction->patches = g_slist_insert_sorted (transaction->patches, + rc_you_patch_ref (patch), + rc_you_patch_compare); } } } diff -ur rcd-2.4.9-old/src/you-module/wrapper.cc rcd-2.4.9/src/you-module/wrapper.cc --- rcd-2.4.9-old/src/you-module/wrapper.cc 2005-10-11 19:11:47.000000000 -0500 +++ rcd-2.4.9/src/you-module/wrapper.cc 2006-06-29 12:11:09.000000000 -0500 @@ -48,7 +48,7 @@ class YouCallbacks : public InstYou::Callbacks { - public: +public: RCPending *transaction_pending; RCPending *transaction_step_pending; @@ -118,103 +118,103 @@ }; extern "C" { - + static const char * rc_you_string_to_char (const std::string str) { return str.c_str (); } - + static RCPackageImportance rc_you_kind_to_rc_importance (PMYouPatch::Kind kind) { RCPackageImportance imp; - + switch (kind) { case PMYouPatch::kind_security: imp = RC_IMPORTANCE_URGENT; break; case PMYouPatch::kind_recommended: imp = RC_IMPORTANCE_SUGGESTED; break; case PMYouPatch::kind_optional: imp = RC_IMPORTANCE_FEATURE; break; case PMYouPatch::kind_patchlevel: case PMYouPatch::kind_document: imp = RC_IMPORTANCE_MINOR; break; - + default: - imp = RC_IMPORTANCE_INVALID; break; + imp = RC_IMPORTANCE_INVALID; break; } - + return imp; } - + static gboolean rc_you_solvable_to_rc_package_spec (RCPackageSpec *spec, PMSolvablePtr solvable) { const char *name; - + name = rc_you_string_to_char (solvable->name ()); spec->nameq = g_quark_from_string (name); - + /* When the patch name starts with "patch-", then yasty doesn't parse it's name and version. For example: 'patch-9250' has name 'patch-9250' and version '0'. - + There's only one thing left to say: *sigh* */ - + if (g_str_has_prefix (name, "patch-")) { int i; gchar **pieces = g_strsplit (name, "-", 0); - + /* Find the last piece */ for (i = 0; pieces[i + 1]; i++) ; - + spec->version = g_strdup (pieces[i]); spec->release = g_strdup (""); - + g_strfreev (pieces); } else { PkgEdition edition = solvable->edition (); - + spec->version = g_strdup (rc_you_string_to_char (edition.version ())); spec->release = g_strdup (rc_you_string_to_char (edition.release ())); - + if (edition.has_epoch ()) { spec->has_epoch = 1; spec->epoch = edition.epoch (); } } - + return TRUE; } - + static RCYouPatch * rc_you_patch_from_yast_patch (PMYouPatchPtr source) { RCYouPatch *patch; const char *script; - + patch = rc_you_patch_new (); patch->arch = rc_arch_from_string (rc_you_string_to_char (source->arch ())); - + rc_you_solvable_to_rc_package_spec ((RCPackageSpec *) patch, (PMSolvablePtr) source); patch->importance = rc_you_kind_to_rc_importance (source->kind ()); patch->size = (guint32) source->patchSize (); patch->channel = RC_CHANNEL_SYSTEM; - + patch->summary = g_strdup (rc_you_string_to_char (source->shortDescription ())); patch->description = g_strdup (rc_you_string_to_char (source->longDescription ())); - + script = rc_you_string_to_char (source->preScript ()); if (script && strlen (script) > 0) patch->pre_script = rc_you_file_new (script); - + script = rc_you_string_to_char (source->postScript ()); if (script && strlen (script) > 0) patch->post_script = rc_you_file_new (script); - + return patch; } static YouCallbacks *you_callback = NULL; - + void rc_you_wrapper_install_patches (RCYouPatchSList *list, RCPending *transaction_pending, @@ -226,7 +226,7 @@ PMYouSettingsPtr settings = new PMYouSettings (); PMYouPatchInfoPtr patch_info = new PMYouPatchInfo (settings); PMYouServer server; - + settings->setLangCode (LangCode ("en")); settings->setReloadPatches (false); settings->setCheckSignatures (false); @@ -234,67 +234,75 @@ settings->setNoExternalPackages (true); settings->setGetAll (false); settings->setGetOnly (false); - + InstYou you (patch_info, settings); you.initProduct (); - + server.setUrl (TMP_YOU_PATH); settings->setPatchServer (server); - + you.retrievePatchDirectory(); you.retrievePatchInfo(); you.selectPatches (PMYouPatch::kind_all); - + + if (you_callback == NULL) + you_callback = new YouCallbacks (); + + you_callback->transaction_pending = transaction_pending; + you_callback->transaction_step_pending = transaction_step_pending; + InstYou::setCallbacks (you_callback); + + // Clear all patches for installation for (it = Y2PM::youPatchManager ().begin (); it != Y2PM::youPatchManager ().end (); ++it) { - GSList *iter; - PMYouPatchPtr you_patch; - RCYouPatch *patch; - gboolean install = FALSE; - - you_patch = (*it)->theObject (); - patch = rc_you_patch_from_yast_patch (you_patch); - - for (iter = list; iter; iter = iter->next) { - RCYouPatch *iter_patch = (RCYouPatch *) iter->data; - - if (rc_package_spec_equal (RC_PACKAGE_SPEC (iter_patch), - RC_PACKAGE_SPEC (patch))) { - install = TRUE; + (*it)->user_unset (); + } + + // Iterate through ordered list of patches and install one at a time + // So that we know the ordering is correct. + GSList *iter; + for (iter = list; iter; iter = iter->next) { + RCYouPatch *iter_patch = (RCYouPatch *) iter->data; + + for (it = Y2PM::youPatchManager ().begin (); + it != Y2PM::youPatchManager ().end (); ++it) { + + PMYouPatchPtr you_patch; + RCYouPatch *patch; + + you_patch = (*it)->theObject (); + patch = rc_you_patch_from_yast_patch (you_patch); + + if (rc_package_spec_equal (RC_PACKAGE_SPEC (patch), + RC_PACKAGE_SPEC (iter_patch))) { + rc_debug (RC_DEBUG_LEVEL_INFO, + "Installing patch %s", + rc_package_spec_to_str_static (RC_PACKAGE_SPEC (patch))); + + (*it)->user_set_install (); + + // TODO Resolve package dependencies + + err = you.processPatches (); + + (*it)->user_unset (); + + if (err) { + gchar *buf = g_strdup_printf ("%s (%s)", + rc_you_string_to_char (err.errstr ()), + rc_you_string_to_char (err.details ())); + g_set_error (error, RC_ERROR, RC_ERROR, buf); + g_free (buf); + goto out; + } break; } + rc_you_patch_unref (patch); } - - if (install) { - rc_debug (RC_DEBUG_LEVEL_INFO, - "Installing patch %s", - rc_package_spec_to_str_static (RC_PACKAGE_SPEC (patch))); - (*it)->user_set_install (); - } else - (*it)->user_unset (); - - rc_you_patch_unref (patch); } - - if (you_callback == NULL) - you_callback = new YouCallbacks (); - - you_callback->transaction_pending = transaction_pending; - you_callback->transaction_step_pending = transaction_step_pending; - InstYou::setCallbacks (you_callback); - - err = you.processPatches (); +out: you_callback->transaction_pending = NULL; you_callback->transaction_step_pending = NULL; - - if (err) { - gchar *buf = g_strdup_printf ("%s (%s)", - rc_you_string_to_char (err.errstr ()), - rc_you_string_to_char (err.details ())); - g_set_error (error, RC_ERROR, RC_ERROR, buf); - g_free (buf); - } - settings = NULL; patch_info = NULL; } @@ -307,11 +315,11 @@ const gchar *filename; RCYouPatchSList *list = NULL; GError *error = NULL; - + if (!g_file_test (INSTALLED_YOU_PATH, (GFileTest)(G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR))) return NULL; - + dir = g_dir_open (INSTALLED_YOU_PATH, 0, &error); if (error) { rc_debug (RC_DEBUG_LEVEL_ERROR, @@ -320,12 +328,12 @@ g_error_free (error); return NULL; } - + while ((filename = g_dir_read_name (dir))) { PMError you_error; PMYouPatchPtr you_patch; RCYouPatch *patch; - + you_error = patch_info->readFile (INSTALLED_YOU_PATH, filename, you_patch); @@ -337,7 +345,7 @@ rc_you_string_to_char (you_error.details ())); continue; } - + patch = rc_you_patch_from_yast_patch (you_patch); you_patch = NULL; if (patch) { @@ -346,9 +354,9 @@ list = g_slist_prepend (list, patch); } } - + g_dir_close (dir); - + return list; } @@ -358,30 +366,30 @@ RCYouPatchSList *list; PMYouSettingsPtr settings = new PMYouSettings (); PMYouPatchInfoPtr patch_info = new PMYouPatchInfo (settings); - + list = read_installed_patches (patch_info, channel); - + settings = NULL; patch_info = NULL; - + return list; } - + void rc_you_wrapper_products_foreach (SuseProductCallback callback, gpointer user_data) { PMYouSettingsPtr settings = new PMYouSettings (); PMYouPatchInfoPtr patchInfo = new PMYouPatchInfo (settings); - + InstYou you (patchInfo, settings); you.initProduct (); - + std::list products = you.settings ()->products(); - + std::list::const_iterator itProd; for (itProd = products.begin (); itProd != products.end (); ++itProd) { PMYouProductPtr prod = *itProd; - + if (callback) if (!callback (rc_you_string_to_char (prod->product ()), rc_you_string_to_char (prod->version ()), @@ -391,9 +399,9 @@ user_data)) break; } - + settings = NULL; patchInfo = NULL; } - + } Only in rcd-2.4.9/src/you-module: wrapper.cc~ diff -ur rcd-2.4.9-old/src/you-module/you-util.c rcd-2.4.9/src/you-module/you-util.c --- rcd-2.4.9-old/src/you-module/you-util.c 2005-10-11 19:11:47.000000000 -0500 +++ rcd-2.4.9/src/you-module/you-util.c 2006-06-29 11:53:01.000000000 -0500 @@ -67,6 +67,56 @@ } xmlrpc_value * +rc_you_patch_package_list(RCYouPatch *patch, xmlrpc_env *env) +{ + xmlrpc_value *package_array; + RCYouPackageSList *iter; + xmlrpc_value *package_info; + xmlrpc_value *based_on; + gchar **based_on_ptr; + RCYouPackage *you_package; + + package_array = xmlrpc_build_value (env, "()"); + for (iter = patch->packages; NULL != iter; iter = iter->next) { + you_package = (RCYouPackage*) iter->data; + + package_info = xmlrpc_struct_new (env); + XMLRPC_FAIL_IF_FAULT (env); + + RCD_XMLRPC_STRUCT_SET_STRING (env, package_info, "filename", + you_package->base_package->filename); + XMLRPC_FAIL_IF_FAULT (env); + + based_on = xmlrpc_build_value (env, "()"); + XMLRPC_FAIL_IF_FAULT (env); + + for (based_on_ptr = you_package->patch_rpm_based_on; + NULL != based_on_ptr && NULL != *based_on_ptr; + ++based_on_ptr) { + xmlrpc_value *tmp = xmlrpc_build_value (env, "s", *based_on_ptr); + XMLRPC_FAIL_IF_FAULT (env); + + xmlrpc_array_append_item (env, based_on, tmp); + xmlrpc_DECREF (tmp); + } + + xmlrpc_struct_set_value (env, package_info, "based_on", based_on); + XMLRPC_FAIL_IF_FAULT (env); + + xmlrpc_array_append_item (env, package_array, package_info); + xmlrpc_DECREF (package_info); + } + +cleanup: + if (env->fault_occurred) { + xmlrpc_DECREF (package_array); + return NULL; + } else { + return package_array; + } +} + +xmlrpc_value * rc_you_patch_to_xmlrpc (RCYouPatch *patch, xmlrpc_env *env) { xmlrpc_value *value = NULL; @@ -130,6 +180,9 @@ RCD_XMLRPC_STRUCT_SET_INT (env, value, "install_only", patch->install_only); + RCD_XMLRPC_STRUCT_SET_STRING (env, value, "summary", patch->summary); + XMLRPC_FAIL_IF_FAULT (env); + cleanup: if (env->fault_occurred) { if (value) @@ -745,12 +798,12 @@ } /* - sysconfig-0.31.0-15.8.i586.rpm - 1235253 - sysconfig-0.31.0-15.8.i586.patch.rpm - 0.31.0-15 0.31.0-15.3 - 424070 - 117300 + sysconfig-0.31.0-15.8.i586.rpm + 1235253 + sysconfig-0.31.0-15.8.i586.patch.rpm + 0.31.0-15 0.31.0-15.3 + 424070 + 117300 */ else if (!strcmp (name, "filename")) { @@ -769,15 +822,9 @@ } else if (!strcmp (name, "patchrpmdlsize")) { ctx->current_package->patch_rpm_dlsize = rc_string_to_guint32_with_default(ctx->text_buffer, 0); + } else if (!strcmp (name, "patchrpmbasedon")) { + ctx->current_package->patch_rpm_based_on = g_strsplit(ctx->text_buffer, " ", 0); } - /* FIXME: Eventually we should parse it, but since we can never - get enough information about patch packages, there's no point - in parsing this - - else if (!strcmp (name, "patchrpmbasedon")) { - - } - */ } static void @@ -805,7 +852,7 @@ break; } - DONE: +DONE: g_free (ctx->text_buffer); ctx->text_buffer = NULL; } @@ -973,3 +1020,206 @@ return count; } + +gint +does_patch_apply (RCYouPatch *patch) +{ + RCYouPackageSList *iter; + gchar **based_on_ptr; + + RCPackman *packman = rc_packman_get_global (); + RCYouPackage *you_package; + gchar *package_name; + gchar *package_name_ptr; + gchar *package_version = NULL; + gchar *package_release = NULL; + + RCPackageSpec package_spec; + + RCPackageSList *installed_package_list = NULL; + RCPackageSList *installed_package_list_iter; + RCPackage *rpm_package; + RCPackage *rpm_package_latest = NULL; + + gboolean package_applies; + + package_spec.version = NULL; + package_spec.release = NULL; + + patch->applies = -1; + + rc_debug (RC_DEBUG_LEVEL_DEBUG, + "Checking to see if patch %s applies...", patch->spec.version); + + if (0 == patch->installed) { + /* Check to see if it is really installed... */ + const char *name; + struct InstalledFlags flags; + flags.patch = patch; + flags.installed = 0; + flags.name_installed = 0; + + name = g_quark_to_string (RC_PACKAGE_SPEC (patch)->nameq); + rc_world_multi_foreach_patch_by_name (RC_WORLD_MULTI (rc_get_world ()), + name, + RC_CHANNEL_SYSTEM, + installed_check_cb, + &flags); + + if (flags.installed) { + patch->applies = 2; + goto out; + } + } + + if (patch->installed) { + patch->applies = 2; + goto out; + } + + /* Iterate through all packages contained in the patch to see + if the package will update something installed on the system. */ + for (iter = patch->packages; NULL != iter; iter=iter->next) { + package_applies = FALSE; + installed_package_list = NULL; + + you_package = (RCYouPackage*) iter->data; + rc_debug(RC_DEBUG_LEVEL_DEBUG, + "Getting package information rpm: %s", you_package->base_package->filename); + + package_name = g_strdup (you_package->base_package->filename); + if (NULL == package_name) { + rc_debug (RC_DEBUG_LEVEL_ERROR, "No memory."); + goto cleanup; + } + + /* Get the package name,version,release */ + if (NULL != (package_name_ptr = g_strrstr (package_name, "."))) { + *package_name_ptr = '\0'; + if (NULL != (package_name_ptr = g_strrstr (package_name, "."))) { + *package_name_ptr = '\0'; + if (NULL != (package_name_ptr = g_strrstr (package_name, "-"))) { + package_release = package_name_ptr+1; + *package_name_ptr = '\0'; + if (NULL != (package_name_ptr = g_strrstr (package_name, "-"))) { + package_version = package_name_ptr + 1; + *package_name_ptr = '\0'; + } else { + rc_debug (RC_DEBUG_LEVEL_ERROR, "Error parsing name(1): %s", + you_package->base_package->filename); + goto cleanup; + } + } else { + rc_debug (RC_DEBUG_LEVEL_ERROR, "Error parsing name(0): %s", + you_package->base_package->filename); + goto cleanup; + } + } else { + rc_debug (RC_DEBUG_LEVEL_ERROR, "Error parsing version(1): %s", + you_package->base_package->filename); + goto cleanup; + } + } else { + rc_debug (RC_DEBUG_LEVEL_ERROR, "Error parsing version(0): %s", + you_package->base_package->filename); + goto cleanup; + } + + rc_debug (RC_DEBUG_LEVEL_DEBUG, + "Checking if package applies - name: %s, version: %s, release: %s", + package_name, package_version, package_release); + + rc_package_spec_init( + &package_spec, + package_name, + 0, + 0, + package_version, + package_release); + + /* Find latest installed package */ + installed_package_list = rc_packman_query (packman,package_name); + installed_package_list_iter = installed_package_list; + rpm_package_latest = NULL; + + while (NULL != installed_package_list_iter) { + rpm_package = (RCPackage*) installed_package_list_iter->data; + + if (NULL == rpm_package_latest) { + rpm_package_latest = rpm_package; + } else if (0 < (rc_packman_version_compare (packman, + RC_PACKAGE_SPEC(rpm_package), + RC_PACKAGE_SPEC(rpm_package_latest)))) { + rpm_package_latest = rpm_package; + } + + installed_package_list_iter = installed_package_list_iter->next; + } + + if (NULL != rpm_package_latest) { + /* Compare versions of the package contained in the patch to + that installed on the system */ + rc_debug (RC_DEBUG_LEVEL_DEBUG, "Latest installed %s - version: %s, release: %s", + package_name, + RC_PACKAGE_SPEC (rpm_package_latest)->version, + RC_PACKAGE_SPEC (rpm_package_latest)->release); + + if (0 < rc_packman_version_compare ( + packman, + &package_spec, + RC_PACKAGE_SPEC(rpm_package_latest))) { + rc_debug(RC_DEBUG_LEVEL_DEBUG,"Package %s applies.",package_name); + package_applies = TRUE; + } + } else { + rc_debug (RC_DEBUG_LEVEL_DEBUG, "%s is not installed.", package_name); + } + + rc_package_slist_unref (installed_package_list); + + installed_package_list = NULL; + + g_free (package_name); + package_name = NULL; + + rc_package_spec_free_members (&package_spec); + package_spec.version = NULL; + package_spec.release = NULL; + + if (-1 == patch->applies) { + if (package_applies) { + patch->applies = 2; + } else { + patch->applies = 0; + } + } else if (!package_applies) { + if (0 != patch->applies) { + patch->applies = 1; + } + } else if (0 == patch->applies) { + patch->applies = 1; + } + } + +cleanup: + if (NULL != package_spec.version) { + g_free (package_spec.version); + } + if (NULL != package_spec.release) { + g_free (package_spec.release); + } + if (NULL != package_name) { + g_free(package_name); + } + if (-1 == patch->applies) { + patch->applies = 1; + } + if (NULL != installed_package_list) { + rc_package_slist_unref (installed_package_list); + } +out: + rc_debug (RC_DEBUG_LEVEL_DEBUG, + "Does patch %s apply = %d", patch->spec.version,patch->applies); + return patch->applies; +} + Only in rcd-2.4.9/src/you-module: you-util.c~ diff -ur rcd-2.4.9-old/src/you-module/you-util.h rcd-2.4.9/src/you-module/you-util.h --- rcd-2.4.9-old/src/you-module/you-util.h 2004-08-27 04:04:28.000000000 -0500 +++ rcd-2.4.9/src/you-module/you-util.h 2006-06-29 11:55:44.000000000 -0500 @@ -43,6 +43,9 @@ xmlrpc_value *rc_you_patch_slist_to_xmlrpc_array (RCYouPatchSList *list, xmlrpc_env *env); +xmlrpc_value *rc_you_patch_package_list (RCYouPatch *patch, + xmlrpc_env *env); + #define RC_YOU_PATCH_FROM_XMLRPC_PATCH 1 << 0 RCYouPatch *rc_xmlrpc_to_rc_you_patch (xmlrpc_value *value, @@ -69,6 +72,19 @@ RCPatchFn callback, gpointer user_data); +/** + * does_patch_apply + * check to see if the patch contains software that applies to this system + * + * @param patch + * @return gint + * 0 - iff patch does not apply to any software installed on this system + * 1 - iff some of the software in the patch applies to software installed on this system + * 2 - if all the software in the patch applies to software installed on this system + * OR the patch is installed + */ +gint does_patch_apply (RCYouPatch *patch); + #ifdef __cplusplus } #endif /* __cplusplus */ Only in rcd-2.4.9/src/you-module: you-util.h~ diff -ur rcd-2.4.9-old/src/you-module/you.c rcd-2.4.9/src/you-module/you.c --- rcd-2.4.9-old/src/you-module/you.c 2005-01-13 09:01:31.000000000 -0600 +++ rcd-2.4.9/src/you-module/you.c 2006-06-29 11:55:06.000000000 -0500 @@ -250,7 +250,7 @@ result = rc_you_patch_to_xmlrpc (info.patch, env); - cleanup: +cleanup: if (env->fault_occurred) return NULL; @@ -358,7 +358,7 @@ xmlrpc_DECREF (xmlrpc_text); } - cleanup: +cleanup: if (patches) { rc_you_patch_slist_unref (patches); @@ -401,7 +401,10 @@ patch->description); XMLRPC_FAIL_IF_FAULT (env); - cleanup: + xmlrpc_struct_set_value (env, result, "packages", rcd_you_patch_package_list (patch,env)); + XMLRPC_FAIL_IF_FAULT (env); + +cleanup: if (env->fault_occurred) { if (patch) rc_you_patch_unref (patch); Only in rcd-2.4.9/src/you-module: you.c~