From b30b6393d09dab48d577f860ebe9ddb2657fd0b9 Mon Sep 17 00:00:00 2001 From: Ivan Yarcev Date: Mon, 21 Aug 2023 14:04:38 +0600 Subject: [PATCH] fixed repository sign saving --- source/ubl-settings-repomanager.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/source/ubl-settings-repomanager.c b/source/ubl-settings-repomanager.c index e30ee8d..891b412 100644 --- a/source/ubl-settings-repomanager.c +++ b/source/ubl-settings-repomanager.c @@ -276,12 +276,10 @@ void on_save(){ if (origin_flagged&&name_flagged){ if (add_packages){ char *sign_check = repo_sign_flagged ? yon_char_new(repo_sign_flagged) : NULL; - repo_sign_flagged=NULL; add_command = yon_char_unite(command, " add -d \"",origin_flagged,"\" -r \"",name_flagged, sign_flagged ? yon_char_append("\" --sign-repo ",sign_flagged):"\"" ," -p ", add_packages,NULL); } if (remove_packages){ char *sign_check = repo_sign_flagged ? yon_char_new(repo_sign_flagged) : NULL; - repo_sign_flagged=NULL; remove_command = yon_char_unite(command, " remove -d \"",origin_flagged,"\" -r \"",name_flagged, sign_flagged ? yon_char_append("\" --sign-repo ",sign_flagged):"\"" , " -p ", remove_packages,NULL); } if (repostatus == 1){ @@ -302,14 +300,12 @@ void on_save(){ dictionary *pck; for_dictionaries(pck,yon_dictionary_get_data(dct,dictionary*)){ signed_packs=yon_char_unite(signed_packs ? yon_char_append(signed_packs,","): "" ,pck->key,NULL); - } char *sign_check = repo_sign_flagged ? yon_char_new(repo_sign_flagged) : NULL; - repo_sign_flagged=NULL; + } char *sign_command = yon_char_unite(command, " add -f -d ",origin_flagged," -r ",name_flagged," --sign-pkg ", dct->key," -p $(find ",origin_flagged,"/pool/overlay -name ", signed_packs,")",NULL); system(sign_command); } } - printf("%s\n",repo_sign_flagged ? repo_sign_flagged:"Null"); if (repo_sign_flagged){ char *repo_sign_command = yon_char_unite(command, " add -f -d ",origin_flagged, " -r ", name_flagged, " --sign-repo ", repo_sign_flagged ,NULL); yon_window_config_add_custom_parameter(yon_char_unite(origin_flagged,NULL),"signatures",repo_sign_flagged_full,YON_TYPE_STRING);