- if(choosealpha) {
- if(!cn->children.nvec) { /* Only need to do this once */
- for(ch = 'A'; ch <= 'Z'; ++ch) {
- byte_xasprintf(&name, "%c", ch);
- newnode(cn, "<letter>", name, name, CN_EXPANDABLE, fill_letter_node);
- }
- newnode(cn, "<letter>", "*", "~", CN_EXPANDABLE, fill_letter_node);
- }
- updated_node(cn, 1);
- filled(cn);
- } else {
- /* More de-duping possible here */
- if(cn->flags & CN_GETTING_ANY)
- return;
- gtk_label_set_text(GTK_LABEL(report_label), "getting files");
- cbd = xmalloc(sizeof *cbd);
- cbd->u.choosenode = cn;
- disorder_eclient_dirs(client, got_dirs, "", 0, cbd);
- cbd = xmalloc(sizeof *cbd);
- cbd->u.choosenode = cn;
- disorder_eclient_files(client, got_files, "", 0, cbd);
- cn->flags |= CN_GETTING_FILES|CN_GETTING_DIRS;
- }
+ /* More de-duping possible here */
+ if(cn->flags & CN_GETTING_ANY)
+ return;
+ gtk_label_set_text(GTK_LABEL(report_label), "getting files");
+ cbd = xmalloc(sizeof *cbd);
+ cbd->u.choosenode = cn;
+ disorder_eclient_dirs(client, got_dirs, "", 0, cbd);
+ cbd = xmalloc(sizeof *cbd);
+ cbd->u.choosenode = cn;
+ disorder_eclient_files(client, got_files, "", 0, cbd);
+ cn->flags |= CN_GETTING_FILES|CN_GETTING_DIRS;
+ gets_in_flight += 2;