Browse code

fix error message when checking .cud files

Tomasz Kojm authored on 2011/09/27 23:41:31
Showing 1 changed files
... ...
@@ -1141,11 +1141,14 @@ static int cvdinfo(const struct optstruct *opts)
1141 1141
 	mprintf("Digital signature: %s\n", cvd->dsig);
1142 1142
     }
1143 1143
     cl_cvdfree(cvd);
1144
-    if((ret = cl_cvdverify(pt))) {
1144
+    if(cli_strbcasestr(pt, ".cud"))
1145
+	mprintf("Verification: Unsigned container\n");
1146
+    else if((ret = cl_cvdverify(pt))) {
1145 1147
 	mprintf("!cvdinfo: Verification: %s\n", cl_strerror(ret));
1146 1148
 	return -1;
1147
-    }
1148
-    mprintf("Verification OK.\n");
1149
+    } else
1150
+	mprintf("Verification OK.\n");
1151
+
1149 1152
     return 0;
1150 1153
 }
1151 1154