Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package s390-tools for openSUSE:Factory 
checked in at 2023-02-18 17:10:18
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/s390-tools (Old)
 and      /work/SRC/openSUSE:Factory/.s390-tools.new.22824 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "s390-tools"

Sat Feb 18 17:10:18 2023 rev:53 rq:1066409 version:2.25.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/s390-tools/s390-tools.changes    2023-02-08 
17:28:57.376753299 +0100
+++ /work/SRC/openSUSE:Factory/.s390-tools.new.22824/s390-tools.changes 
2023-02-18 17:10:19.758714616 +0100
@@ -1,0 +2,8 @@
+Thu Feb 16 16:24:33 UTC 2023 - José Gómez <jose.go...@suse.com>
+
+- Implemented read_values -u. The result of -u is a unique identifier composed 
of:
+  * Machine Serial Number.
+  * LPAR Name.
+  * VM Name (can be optional).
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ s390-tools.spec ++++++
--- /var/tmp/diff_new_pack.zNF9gs/_old  2023-02-18 17:10:20.810721258 +0100
+++ /var/tmp/diff_new_pack.zNF9gs/_new  2023-02-18 17:10:20.814721283 +0100
@@ -1,7 +1,7 @@
 #
 # spec file for package s390-tools
 #
-# Copyright (c) 2001-2023 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed

++++++ read_values.c ++++++
--- /var/tmp/diff_new_pack.zNF9gs/_old  2023-02-18 17:10:21.262724112 +0100
+++ /var/tmp/diff_new_pack.zNF9gs/_new  2023-02-18 17:10:21.266724137 +0100
@@ -37,9 +37,9 @@
 #define        WITHOUT_KEY     0
 #define        WITH_KEY        1
 
-static char *versionstring     = "Version 1.0.2 2020-03-30 23:30";
+static char *versionstring     = "Version 1.0.3 2023-02-16 17:00";
 
-static char *version           = "1.0.2";
+static char *version           = "1.0.3";
 
 void   *configuration_handle   = NULL;
 int    layers                  = -1;
@@ -339,12 +339,47 @@
 /*                                                                           */
 /*     print out the uuid for this machine                                   */
 /*                                                                           */
-/*     TODO!                                                                 */
+/*                                                                           */
 /*                                                                           */
 
/******************************************************************************/
-void print_uuid()
+int print_uuid()
 {
-return;
+       const char      *result_string = NULL;
+       int erg;
+
+       erg = qc_get_attribute_string(configuration_handle, qc_sequence_code, 
0, &result_string);
+       if (erg != 1)
+       {
+               puts("Error reading the Serial Number");
+               return 1;
+       }
+       printf("%s", result_string);
+
+       result_string = NULL;
+
+       erg = qc_get_attribute_string(configuration_handle, qc_layer_name, 1, 
&result_string);
+       if (erg != 1)
+       {
+               puts("Error reading the LPAR Name");
+               return 1;
+       }
+       printf("-%s", result_string);
+
+       result_string = NULL;
+       if (layers  > 2) {
+
+               erg = qc_get_attribute_string(configuration_handle, 
qc_layer_name, 3, &result_string);
+               if (erg != 1)
+               {
+                       puts("Error Reading the VM Name");
+                       return 1;
+               }
+               printf("-%s", result_string);
+
+               result_string = NULL;
+       }
+       printf("\n", result_string);
+       return 0;
 } /* print_uuid */
 
 
/******************************************************************************/
@@ -501,7 +536,7 @@
                return 1;
           } /* endif */
           /* still not im[plemented thatfore set to zero */
-          create_uuid = list_attr = print_attr = 0;
+          list_attr = print_attr = 0;
           if (print_attr != 0) {
                print_user_attribute(NULL, print_attribute_param, layers);
                goto main_exit;
@@ -523,7 +558,9 @@
                goto main_exit;
           } /* endif */
           if (create_uuid != 0) {
-               print_uuid();
+               if(print_uuid() == 1){
+                       goto main_exit_error;
+               }
                goto main_exit;
           } /* endif */
           help();
@@ -535,6 +572,10 @@
                setenv("QC_AUTODUMP", "0", 1);
                qc_close(configuration_handle_tmp);
        } /* endif */
+
 return 0;
+
+main_exit_error:
+return 1;
 } /* end main */
 

Reply via email to