Changeset 3169 in MondoRescue for branches/3.0


Ignore:
Timestamp:
Jul 26, 2013, 9:15:42 AM (11 years ago)
Author:
Bruno Cornec
Message:
  • Fix #690 by adding support for tape block size question in the GUI
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.0/mondo/src/common/libmondo-devices.c

    r3165 r3169  
    24262426        }
    24272427        mr_free(tmp);
    2428         log_msg(4, "sz_size = %s", sz_size);
    2429         sz_size[0] = '\0';
    2430 
    2431         if (sz_size[0] == '\0') {
    2432             bkpinfo->media_size = 0;
    2433         } else {
    2434             bkpinfo->media_size = friendly_sizestr_to_sizelong(sz_size) / 2 - 50;
    2435         }
     2428
     2429        if (!popup_and_get_string
     2430            ("Tape block size?",
     2431             "What is the block size of your tape streamer?",
     2432             sz_size, 15)) {
     2433            log_to_screen("User has chosen not to backup the PC");
     2434            finish(1);
     2435        }
     2436        bkpinfo->internal_tape_block_size = atol(sz_size);
     2437        if (bkpinfo->internal_tape_block_size <= 0) {
     2438            log_to_screen("User has chosen not to backup the PC");
     2439            finish(1);
     2440        }
     2441
     2442        bkpinfo->media_size = 0;
    24362443        log_msg(4, "media_size = %ld", bkpinfo->media_size);
    2437         if (bkpinfo->media_size <= 0) {
    2438             bkpinfo->media_size = 0;
    2439         }
     2444
    24402445        bkpinfo->use_obdr = ask_me_yes_or_no
    24412446            ("Do you want to activate OBDR support for your tapes ?");
Note: See TracChangeset for help on using the changeset viewer.