On 11.07.2012 13:30, Uwe Gansert wrote:

Here is a simple patch that copies the kopts to the xen distro.

sorry, there is a check missing in the patch if there is a xen distro at all.
This patch checks that.

--
ciao, Uwe Gansert

SUSE LINUX Products GmbH, HRB 16746 (AG Nürnberg)
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer
Home: http://www.suse.de/~ug - Blog: http://suse.gansert.net
listening to: "Crack It" by THYX


diff --git a/java/code/src/com/redhat/rhn/manager/kickstart/tree/BaseTreeEditOperation.java b/java/code/src/com/redhat/rhn/manager/kickstart/tree/BaseTreeEditOperation.java
index 7fee82e..048c679 100644
--- a/java/code/src/com/redhat/rhn/manager/kickstart/tree/BaseTreeEditOperation.java
+++ b/java/code/src/com/redhat/rhn/manager/kickstart/tree/BaseTreeEditOperation.java
@@ -95,11 +95,18 @@ public abstract class BaseTreeEditOperation extends BasePersistOperation {
 
             Distro distro = Distro.lookupById(CobblerXMLRPCHelper.getConnection(
                     this.getUser()), tree.getCobblerId());
+            Distro xen_distro = Distro.lookupById(CobblerXMLRPCHelper.getConnection(
+            		this.getUser()), tree.getCobblerXenId());
 
             Map kOpts = distro.getKernelOptions();
             distro.setKernelOptions(getKernelOptions());
             distro.setKernelPostOptions(getPostKernelOptions());
             distro.save();
+            if (xen_distro != null) {
+            	xen_distro.setKernelOptions(getKernelOptions());
+            	xen_distro.setKernelPostOptions(getPostKernelOptions());
+            	xen_distro.save();
+            }
         }
         catch (XmlRpcException xe) {
             HibernateFactory.rollbackTransaction();
_______________________________________________
Spacewalk-devel mailing list
Spacewalk-devel@redhat.com
https://www.redhat.com/mailman/listinfo/spacewalk-devel

Reply via email to