Changeset 6100

Show
Ignore:
Timestamp:
03/07/09 14:20:39 (3 years ago)
Author:
westram
Message:
  • fix warning "format not a string literal and no format arguments"
    • GB_export_error -> GB_export_error/GB_export_errorf
Location:
trunk
Files:
62 modified

Legend:

Unmodified
Added
Removed
  • trunk/ARBDB/adGene.c

    r6098 r6100  
    569569    gb_assert(GEN_find_origin_organism(gb_pseudo, 0) == 0); 
    570570 
    571     error = GB_export_error("The gene-species '%s' refers to an unknown organism (%s)\n" 
    572                             "This occurs if you rename or delete the organism or change the entry\n" 
    573                             "'ARB_origin_species' and will most likely cause serious problems.", 
    574                             GBT_read_name(gb_pseudo), 
    575                             GEN_origin_organism(gb_pseudo)); 
     571    error = GB_export_errorf("The gene-species '%s' refers to an unknown organism (%s)\n" 
     572                             "This occurs if you rename or delete the organism or change the entry\n" 
     573                             "'ARB_origin_species' and will most likely cause serious problems.", 
     574                             GBT_read_name(gb_pseudo), 
     575                             GEN_origin_organism(gb_pseudo)); 
    576576 
    577577    return error; 
  • trunk/ARBDB/adRevCompl.c

    r5390 r6100  
    105105        default: { 
    106106            *T_or_U = 0; 
    107             return GB_export_error("%s not available for alignment-type", supposed_target); 
     107            return GB_export_errorf("%s not available for alignment-type", supposed_target); 
    108108        } 
    109109    } 
  • trunk/ARBDB/ad_load.c

    r6099 r6100  
    714714    if (!GBCONTAINER_MAIN(gbd)->allow_corrupt_file_recovery) { 
    715715        if (!recovery_reason) { recovery_reason = GB_await_error(); } 
    716         GB_export_error("Aborting recovery (because recovery mode is disabled)\n" 
    717                         "Error causing recovery: '%s'\n" 
    718                         "Part of data may be recovered using 'arb_repair yourDB.arb newName.arb'\n" 
    719                         "(Note: Recovery doesn't work if the error occurs while loading a quick save file)", 
    720                         recovery_reason); 
    721         /*         GB_export_error("Your data file is corrupt.\n" */ 
    722         /*                         "   This may happen if \n" */ 
    723         /*                         "   - there is a hardware error (e.g a drive crash),\n" */ 
    724         /*                         "   - data is corrupted by bad internet connections,\n" */ 
    725         /*                         "   - data is destroyed by the program or\n" */ 
    726         /*                         "   - if it isn't an arb file\n" */ 
    727         /*                         "   You may recover part of your data by running\n" */ 
    728         /*                         "       arb_repair old_arb_file panic.arb\n"); */ 
     716        GB_export_errorf("Aborting recovery (because recovery mode is disabled)\n" 
     717                         "Error causing recovery: '%s'\n" 
     718                         "Part of data may be recovered using 'arb_repair yourDB.arb newName.arb'\n" 
     719                         "(Note: Recovery doesn't work if the error occurs while loading a quick save file)", 
     720                         recovery_reason); 
    729721        return -1; 
    730722    } 
     
    11981190            } 
    11991191            else { 
    1200                 GB_export_error("FastLoad-File index conflict (%s)", map_path); 
     1192                GB_export_errorf("FastLoad-File index conflict (%s)", map_path); 
    12011193            } 
    12021194        } 
  • trunk/ARBDB/ad_prot.h

    r6099 r6100  
    3737char *GB_find_latest_file P_((const char *dir, const char *mask)); 
    3838void GB_raise_critical_error P_((const char *msg)); 
    39 GB_ERROR GB_export_error P_((const char *templat, ...)) __ATTR__FORMAT(1); 
     39GB_ERROR GB_export_error P_((const char *error)); 
     40GB_ERROR GB_export_errorf P_((const char *templat, ...)) __ATTR__FORMAT(1); 
    4041GB_ERROR GB_export_IO_error P_((const char *action, const char *filename)); 
    4142GB_ERROR GB_print_error P_((void)); 
  • trunk/ARBDB/ad_save_load.c

    r6057 r6100  
    148148    } 
    149149    else { 
    150         error = GB_export_error("WARNING: Cannot create file '%s'\n" 
    151                                 "   Your database is saved, but you should check write permissions\n" 
    152                                 "   in the destination directory", 
    153                                 fullref); 
     150        error = GB_export_errorf("WARNING: Cannot create file '%s'\n" 
     151                                 "   Your database is saved, but you should check write permissions\n" 
     152                                 "   in the destination directory", 
     153                                 fullref); 
    154154    } 
    155155 
     
    171171    } 
    172172    else { 
    173         error = GB_export_error("Cannot add your file '%s'\n" 
    174                                 "   to the list of references of '%s'\n" 
    175                                 "   Please ask the owner of that file not to delete it\n" 
    176                                 "   or save the entire database (that's recommended!)", 
    177                                 fullchanges,fullref); 
     173        error = GB_export_errorf("Cannot add your file '%s'\n" 
     174                                 "   to the list of references of '%s'\n" 
     175                                 "   Please ask the owner of that file not to delete it\n" 
     176                                 "   or save the entire database (that's recommended!)", 
     177                                 fullchanges,fullref); 
    178178    } 
    179179 
     
    623623{ 
    624624    long p = (long)ftell(in); 
    625     GB_export_error("%s in reading GB_file (loc %li=%lX) reading %s\n", 
     625    GB_export_errorf("%s in reading GB_file (loc %li=%lX) reading %s\n", 
    626626                    text,p,p,GB_KEY(gbd)); 
    627627    GB_print_error(); 
     
    11251125    fmaster = fopen( Main->path, "r" ); /* old master !!!! */ 
    11261126    if (!fmaster){      /* Oh no, where is my old master */ 
    1127         return GB_export_error("Save Changes is missing master ARB file '%s',\n" 
    1128                                "    save database first", Main->path); 
     1127        return GB_export_errorf("Save Changes is missing master ARB file '%s',\n" 
     1128                                "    save database first", Main->path); 
    11291129    } 
    11301130    fclose(fmaster); 
    11311131    if (GB_unlink(path)<0){ 
    1132         return GB_export_error("File '%s' already exists and cannot be deleted\n(Reason: %s)",path, GB_await_error()); 
     1132        return GB_export_errorf("File '%s' already exists and cannot be deleted\n(Reason: %s)",path, GB_await_error()); 
    11331133    };      /* delete old file */ 
    11341134 
     
    12091209    if (refpath && strcmp(refpath, Main->path) ) 
    12101210    { 
    1211         return GB_export_error("Internal ARB Error, master file rename '%s'!= '%s',\n" 
    1212                                "    save database first", refpath,Main->path); 
     1211        return GB_export_errorf("Internal ARB Error, master file rename '%s'!= '%s',\n" 
     1212                                "    save database first", refpath,Main->path); 
    12131213    } 
    12141214 
     
    12171217    if (!fmaster) /* Oh no, where is my old master */ 
    12181218    { 
    1219         return GB_export_error("Quick save is missing master ARB file '%s',\n" 
    1220                                "    save database first", refpath); 
     1219        return GB_export_errorf("Quick save is missing master ARB file '%s',\n" 
     1220                                "    save database first", refpath); 
    12211221    } 
    12221222    fclose(fmaster); 
     
    12351235    sec_path = gb_overwriteName(path); 
    12361236 
    1237     if ((out = fopen(sec_path, "w")) == NULL) return GB_export_error("ARBDB ERROR: Cannot save file to '%s'",sec_path); 
     1237    if ((out = fopen(sec_path, "w")) == NULL) return GB_export_errorf("ARBDB ERROR: Cannot save file to '%s'",sec_path); 
    12381238 
    12391239    slevel = Main->security_level; 
     
    12571257    Main->transaction = translevel; 
    12581258    erg |= fclose(out); 
    1259     if (erg!=0) return GB_export_error("Cannot write to '%s'",sec_path); /* was: '%s%%'",path);*/ 
     1259    if (erg!=0) return GB_export_errorf("Cannot write to '%s'",sec_path); /* was: '%s%%'",path);*/ 
    12601260 
    12611261    if (GB_rename_file(sec_path,path)) return GB_get_error(); 
     
    13291329            lslash[0] = 0; 
    13301330            if (!GB_is_directory(fullpath)) { 
    1331                 err = GB_export_error("Directory '%s' doesn't exist", fullpath); 
     1331                err = GB_export_errorf("Directory '%s' doesn't exist", fullpath); 
    13321332            } 
    13331333            lslash[0] = '/'; 
     
    13421342        mode = GB_mode_of_link(path); 
    13431343        if (mode >=0 && !(mode & S_IWUSR)){ /* no write access -> lookes like a master file */ 
    1344             return GB_export_error( 
    1345                                    "Your selected file '%s' already exists and is write protected\n" 
    1346                                    "    It looks like that your file is a master arb file which is\n" 
    1347                                    "    used by some xxx.a?? quicksave databases\n" 
    1348                                    "    If you want to save it nevertheless, delete it first !!!", 
    1349                                    path); 
     1344            return GB_export_errorf( 
     1345                                    "Your selected file '%s' already exists and is write protected\n" 
     1346                                    "    It looks like that your file is a master arb file which is\n" 
     1347                                    "    used by some xxx.a?? quicksave databases\n" 
     1348                                    "    If you want to save it nevertheless, delete it first !!!", 
     1349                                    path); 
    13501350        } 
    13511351    } 
    13521352    if ( strchr(flags,'n')){ 
    13531353        if (GB_time_of_file(path)){ 
    1354             return GB_export_error( "Your destination file '%s' already exists.\n" 
     1354            return GB_export_errorf("Your destination file '%s' already exists.\n" 
    13551355                                    "\tDelete it by hand first",path ); 
    13561356        } 
  • trunk/ARBDB/adali.c

    r6077 r6100  
    176176    if ( (error = GB_check_key(alignment_name)) ) return error; 
    177177    if (strncmp(alignment_name,"ali_",4)){ 
    178         return GB_export_error("your alignment_name '%s' must start with 'ali_'", 
    179                                alignment_name); 
     178        return GB_export_errorf("your alignment_name '%s' must start with 'ali_'", 
     179                                alignment_name); 
    180180    } 
    181181    return 0; 
     
    269269    if (!result) { 
    270270        ad_assert(error); 
    271         GB_export_error("in GBT_create_alignment: %s", error); 
     271        GB_export_errorf("in GBT_create_alignment: %s", error); 
    272272    } 
    273273#if defined(DEBUG) 
     
    716716     
    717717    if (!gb_alignment_name) { 
    718         GB_export_error("alignment '%s' not found", aliname); 
     718        GB_export_errorf("alignment '%s' not found", aliname); 
    719719        return NULL; 
    720720    } 
     
    740740        GB_pop_my_security(gb_main); 
    741741    } 
    742     else error = GB_export_error("Alignment '%s' not found", aliname); 
     742    else error = GB_export_errorf("Alignment '%s' not found", aliname); 
    743743    return error; 
    744744} 
     
    930930    if (error) { 
    931931        char *id = GEN_global_gene_identifier(gb_gene, gb_species); 
    932         error    = GB_export_error("Can't read sequence of '%s' (Reason: %s)", id, error); 
     932        error    = GB_export_errorf("Can't read sequence of '%s' (Reason: %s)", id, error); 
    933933        free(id); 
    934934        free(result); 
  • trunk/ARBDB/adcomm.c

    r6062 r6100  
    466466        gbd = (GBDATA *) buffer[2]; 
    467467        if ( (error = gbcm_test_address((long *)gbd,GBTUM_MAGIC_NUMBER))) { 
    468             GB_export_error("address %p not valid 3712",gbd); 
     468            GB_export_errorf("address %p not valid 3712",gbd); 
    469469            GB_print_error(); 
    470470            return GBCM_SERVER_FAULT; 
     
    579579        if (anz<0) continue; 
    580580        if (anz==0) { 
    581             GB_export_error("ARB_DB ERROR CLIENT TRANSACTION TIMEOUT, CLIENT DISCONNECTED (I waited %lu seconds)",timeout.tv_sec); 
     581            GB_export_errorf("ARB_DB ERROR CLIENT TRANSACTION TIMEOUT, CLIENT DISCONNECTED (I waited %lu seconds)",timeout.tv_sec); 
    582582            GB_print_error(); 
    583583            gb_local->running_client_transaction = ARB_ABORT; 
     
    650650        if (anz<0) continue; 
    651651        if (anz==0) { 
    652             GB_export_error("ARB_DB ERROR CLIENT TRANSACTION TIMEOUT, CLIENT DISCONNECTED (I waited %lu seconds)",timeout.tv_sec); 
     652            GB_export_errorf("ARB_DB ERROR CLIENT TRANSACTION TIMEOUT, CLIENT DISCONNECTED (I waited %lu seconds)",timeout.tv_sec); 
    653653            GB_print_error(); 
    654654            gb_local->running_client_transaction = ARB_ABORT; 
     
    680680    sin = sin; 
    681681    if ( (error = gbcm_test_address((long *)gbd,GBTUM_MAGIC_NUMBER)) ) { 
    682         GB_export_error("address %p not valid 4783",gbd); 
     682        GB_export_errorf("address %p not valid 4783",gbd); 
    683683        GB_print_error(); 
    684684        if (error) return GBCM_SERVER_FAULT; 
     
    706706    sin = sin; 
    707707    if ( (error = gbcm_test_address((long *)gbd,GBTUM_MAGIC_NUMBER)) ) { 
    708         GB_export_error("address %p not valid 4356",gbd); 
     708        GB_export_errorf("address %p not valid 4356",gbd); 
    709709        GB_print_error(); 
    710710        return GBCM_SERVER_FAULT; 
     
    830830 
    831831    if ( (error = gbcm_test_address((long *) gbd, GBTUM_MAGIC_NUMBER)) ) { 
    832         GB_export_error("address %p not valid 8734", gbd); 
     832        GB_export_errorf("address %p not valid 8734", gbd); 
    833833        GB_print_error(); 
    834834        return GBCM_SERVER_FAULT; 
     
    914914 
    915915    if ( (error = gbcm_test_address((long *) gbd, GBTUM_MAGIC_NUMBER))) { 
    916         GB_export_error("address %p not valid 8734", gbd); 
     916        GB_export_errorf("address %p not valid 8734", gbd); 
    917917        GB_print_error(); 
    918918        return GBCM_SERVER_FAULT; 
     
    14791479    if (irror) { 
    14801480        GB_ERROR error; 
    1481         error = GB_export_error("GB_unfold (%s) read error",GB_read_key_pntr((GBDATA*)gbd)); 
     1481        error = GB_export_errorf("GB_unfold (%s) read error",GB_read_key_pntr((GBDATA*)gbd)); 
    14821482        return error; 
    14831483    } 
     
    14971497{ 
    14981498    if (gbcm_write_two(GB_MAIN(gbd)->c_link->socket,GBCM_COMMAND_PUT_UPDATE,gbd->server_id) ) { 
    1499         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1499        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    15001500    } 
    15011501    return 0; 
     
    15081508    int socket = Main->c_link->socket; 
    15091509    if (gbcm_write_two(socket,GBCM_COMMAND_PUT_UPDATE_END,gbd->server_id) ) { 
    1510         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1510        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    15111511    } 
    15121512    gbcm_write_flush(socket); 
     
    15321532    GBCONTAINER *father = GB_FATHER(gbd); 
    15331533 
    1534     if (!father) return GB_export_error("internal error #2453:%s",GB_KEY(gbd)); 
     1534    if (!father) return GB_export_errorf("internal error #2453:%s",GB_KEY(gbd)); 
    15351535    if (gbcm_write_two(socket,GBCM_COMMAND_PUT_UPDATE_CREATE,father->server_id) ) { 
    1536         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1536        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    15371537    } 
    15381538    buffer = (long *)GB_give_buffer(1014); 
     
    15471547                        GBCM_COMMAND_PUT_UPDATE_DELETE, 
    15481548                        gbd->server_id) ) { 
    1549         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1549        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    15501550    }else{ 
    15511551        return 0; 
     
    15591559    GB_MAIN_TYPE *Main = GB_MAIN(gbd); 
    15601560 
    1561     if (!GB_FATHER(gbd)) return GB_export_error("internal error #2453 %s",GB_KEY(gbd)); 
     1561    if (!GB_FATHER(gbd)) return GB_export_errorf("internal error #2453 %s",GB_KEY(gbd)); 
    15621562    if (gbcm_write_two(Main->c_link->socket,GBCM_COMMAND_PUT_UPDATE_UPDATE,gbd->server_id) ) { 
    1563         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1563        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    15641564    } 
    15651565    buffer = (long *)GB_give_buffer(1016); 
     
    16121612    buffer = (long *)GB_give_buffer(1026); 
    16131613    if (gbcm_write_two(Main->c_link->socket,GBCM_COMMAND_BEGIN_TRANSACTION,Main->clock) ) { 
    1614         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1614        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    16151615    } 
    16161616    if (gbcm_write_flush(socket)) { 
     
    16821682 
    16831683    if (gbcm_write_two(socket,GBCM_COMMAND_INIT_TRANSACTION,Main->clock) ) { 
    1684         return GB_export_error("Cannot send '%s' to server",GB_KEY((GBDATA*)gbd)); 
     1684        return GB_export_errorf("Cannot send '%s' to server",GB_KEY((GBDATA*)gbd)); 
    16851685    } 
    16861686    gbcm_write_string(socket,Main->this_user->username); 
     
    17241724 
    17251725    if (gbcm_write_two(socket,GBCM_COMMAND_COMMIT_TRANSACTION,gbd->server_id) ) { 
    1726         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1726        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    17271727    } 
    17281728    if (gbcm_write_flush(socket)) { 
     
    17391739    int socket = Main->c_link->socket; 
    17401740    if (gbcm_write_two(socket,GBCM_COMMAND_ABORT_TRANSACTION,gbd->server_id) ) { 
    1741         return GB_export_error("Cannot send '%s' to server",GB_KEY(gbd)); 
     1741        return GB_export_errorf("Cannot send '%s' to server",GB_KEY(gbd)); 
    17421742    } 
    17431743    if (gbcm_write_flush(socket)) { 
     
    19511951    result = gbcm_read_string(socket); 
    19521952    gbcm_read_flush(socket); 
    1953     if (result) GB_export_error("%s",result); 
     1953    if (result) GB_export_errorf("%s",result); 
    19541954    return result; 
    19551955} 
     
    20262026        return 0; 
    20272027    } 
    2028     return GB_export_error("Too many users in this database: User '%s' ",user); 
     2028    return GB_export_errorf("Too many users in this database: User '%s' ",user); 
    20292029} 
    20302030 
     
    20672067        } 
    20682068    } 
    2069     return GB_export_error("User '%s' not logged in",user); 
     2069    return GB_export_errorf("User '%s' not logged in",user); 
    20702070} 
    20712071 
  • trunk/ARBDB/adcompr.c

    r6099 r6100  
    10131013                } 
    10141014                else{ 
    1015                     error = GB_export_error("Internal Error: Cannot uncompress data of field '%s'",GB_read_key_pntr(gbd)); 
     1015                    error = GB_export_errorf("Internal Error: Cannot uncompress data of field '%s'",GB_read_key_pntr(gbd)); 
    10161016                } 
    10171017 
  • trunk/ARBDB/adindex.c

    r5971 r6100  
    800800    GB_MAIN_TYPE *Main = GB_MAIN(gbd); 
    801801    if (memsize < _GBCMC_UNDOCOM_SET_MEM){ 
    802         return  GB_export_error("Too less UNDO memory specified: should be more than %i", 
     802        return GB_export_errorf("Not enough UNDO memory specified: should be more than %i", 
    803803                                _GBCMC_UNDOCOM_SET_MEM); 
    804804    } 
  • trunk/ARBDB/aditem.c

    r6083 r6100  
    4848    if (error) { 
    4949        gb_item = 0; 
    50         GB_export_error("Can't create %s '%s': %s", itemname, id, error); 
     50        GB_export_errorf("Can't create %s '%s': %s", itemname, id, error); 
    5151    } 
    5252 
     
    9292        GBDATA     *gb_any   = GB_find(gb_item_data, id_field, down_2_level); 
    9393        const char *itemname = gb_any ? GB_read_key_pntr(GB_get_father(gb_any)) : "<item>"; 
    94         GB_export_error("Could not find %s with %s '%s'", itemname, id_field, id_value); 
     94        GB_export_errorf("Could not find %s with %s '%s'", itemname, id_field, id_value); 
    9595    } 
    9696    return gb_found; 
  • trunk/ARBDB/adlang1.c

    r6057 r6100  
    212212            freeset(params, NULL); 
    213213            res = GBS_strclose(str); 
    214             err = GB_export_error("Unknown Parameter '%s' in command '%s'\n\tPARAMETERS:\n%s",argv[i].str,com,res); 
     214            err = GB_export_errorf("Unknown Parameter '%s' in command '%s'\n\tPARAMETERS:\n%s",argv[i].str,com,res); 
    215215            free(res); 
    216216            return err; 
     
    875875    else if (strcmp(args->command, "upper") == 0) mode = 1; 
    876876    else if (strcmp(args->command, "caps")  == 0) mode = 2; 
    877     else return GB_export_error("Unknown command '%s'", args->command); 
     877    else return GB_export_errorf("Unknown command '%s'", args->command); 
    878878 
    879879    if (args->cparam!=0) return GBS_global_string("syntax: %s (no parameters)", args->command); 
     
    22972297    if (error) { 
    22982298        gb_assert(!seq); 
    2299         GB_export_error("%s", error); 
     2299        GB_export_error(error); 
    23002300    } 
    23012301 
  • trunk/ARBDB/adlink.c

    r5356 r6100  
    1717    s = strchr(link,':'); 
    1818    if (!s){ 
    19         GB_export_error("Your link '%s' does not contain a ':' character",link); 
     19        GB_export_errorf("Your link '%s' does not contain a ':' character",link); 
    2020        return 0; 
    2121    } 
     
    2525    *s = c; 
    2626    if (!lf){ 
    27         GB_export_error("Your link tag '%s' is unknown to the system",link); 
     27        GB_export_errorf("Your link tag '%s' is unknown to the system",link); 
    2828        return 0; 
    2929    } 
  • trunk/ARBDB/admap.c

    r5847 r6100  
    677677 error: 
    678678 
    679     GB_export_error("Error while saving FastLoad-File '%s'", opath); 
     679    GB_export_errorf("Error while saving FastLoad-File '%s'", opath); 
    680680    GB_unlink_or_warn(opath, NULL); 
    681681 
  • trunk/ARBDB/admatch.c

    r5839 r6100  
    749749            *(bar++) = 0; 
    750750        } else { 
    751             GB_export_error("SRT ERROR: no '=' found in command '%s' (position > %zi)", icommand, doppelpunkt-command+1); 
     751            GB_export_errorf("SRT ERROR: no '=' found in command '%s' (position > %zi)", icommand, doppelpunkt-command+1); 
    752752            free(command); 
    753753            free(in); 
     
    848848                free(command); 
    849849                free(in); 
    850                 GB_export_error("%s",error); 
     850                GB_export_error(error); 
    851851                return 0; 
    852852            } 
  • trunk/ARBDB/adname.c

    r6020 r6100  
    9090 
    9191        if (gb_found_species && gb_species != gb_found_species) { 
    92             return GB_export_error("A species named '%s' already exists.",newname); 
     92            return GB_export_errorf("A species named '%s' already exists.",newname); 
    9393        } 
    9494    } 
    9595 
    9696    if (!gb_species) { 
    97         return GB_export_error("Expected that a species named '%s' exists (maybe there are duplicate species, database might be corrupt)",oldname); 
     97        return GB_export_errorf("Expected that a species named '%s' exists (maybe there are duplicate species, database might be corrupt)",oldname); 
    9898    } 
    9999 
  • trunk/ARBDB/adquery.c

    r6099 r6100  
    441441            GB_TYPES oldType = GB_TYPE(gbsp); 
    442442            if (create != oldType) { /* type mismatch */ 
    443                 GB_export_error("Inconsistent type for field '%s' (existing=%i, expected=%i)", str, oldType, create); 
     443                GB_export_errorf("Inconsistent type for field '%s' (existing=%i, expected=%i)", str, oldType, create); 
    444444                return NULL; 
    445445            } 
     
    481481            if (seperator == '-') { 
    482482                if ((*s2)  != '>'){ 
    483                     GB_export_error("Invalid key for gb_search '%s'",str); 
     483                    GB_export_errorf("Invalid key for gb_search '%s'",str); 
    484484                    GB_print_error(); 
    485485                    return NULL; 
     
    554554    long type = GB_TYPE(gbd); 
    555555    if (type != expected_type) { 
    556         GB_export_error("Field '%s' has wrong type (found=%li, expected=%li)", fieldname, type, expected_type); 
     556        GB_export_errorf("Field '%s' has wrong type (found=%li, expected=%li)", fieldname, type, expected_type); 
    557557        gbd = 0; 
    558558    } 
     
    946946                    const char *hp = gbs_search_second_x(s1+1); 
    947947                    if (!hp){ 
    948                         GB_export_error("unbalanced '\"' in '%s'",commands); 
     948                        GB_export_errorf("unbalanced '\"' in '%s'",commands); 
    949949                        return NULL; 
    950950                    } 
     
    11631163    } 
    11641164 
    1165     GB_export_error("Command '%s' failed:\nReason: %s", commands, error); 
     1165    GB_export_errorf("Command '%s' failed:\nReason: %s", commands, error); 
    11661166    return NULL; 
    11671167} 
  • trunk/ARBDB/adseqcompr.c

    r5839 r6100  
    416416        int leafcount = g_b_count_leafs(tree); 
    417417        if (!leafcount) { 
    418             error = GB_export_error("Tree contains no sequences with data in '%s'", ali_name); 
     418            error = GB_export_errorf("Tree contains no sequences with data in '%s'", ali_name); 
    419419        } 
    420420        else { 
     
    726726    ctree = (GB_CTREE *)GBT_read_tree(gb_main,(char *)tree_name,-sizeof(GB_CTREE)); 
    727727    if (!ctree) { 
    728         error = GB_export_error("Tree %s not found in database",tree_name); 
     728        error = GB_export_errorf("Tree %s not found in database",tree_name); 
    729729    } 
    730730    else { 
  • trunk/ARBDB/adsocket.c

    r6099 r6100  
    358358                return "Could not open socket on Server"; 
    359359            } 
    360             if (chmod(mach_name[0],0777)) return GB_export_error("Cannot change mode of socket '%s'",mach_name[0]); 
     360            if (chmod(mach_name[0],0777)) return GB_export_errorf("Cannot change mode of socket '%s'",mach_name[0]); 
    361361        } 
    362362        *unix_name = mach_name[0]; 
     
    646646GB_ERROR GB_symlink(const char *name1, const char *name2){  /* name1 is the existing file !!! */ 
    647647    if (symlink(name1,name2)<0){ 
    648         return GB_export_error("Cannot create symlink '%s' to file '%s'",name2,name1); 
     648        return GB_export_errorf("Cannot create symlink '%s' to file '%s'",name2,name1); 
    649649    } 
    650650    return 0; 
     
    653653GB_ERROR GB_set_mode_of_file(const char *path,long mode) 
    654654{ 
    655     if (chmod(path, (int)mode)) return GB_export_error("Cannot change mode of '%s'",path); 
     655    if (chmod(path, (int)mode)) return GB_export_errorf("Cannot change mode of '%s'",path); 
    656656    return 0; 
    657657} 
     
    735735    } 
    736736    if (buffer == MAP_FAILED){ 
    737         GB_export_error("GB_map_file: Error Out of Memory: mmap failes (errno: %i)", errno); 
     737        GB_export_errorf("GB_map_file: Error Out of Memory: mmap failes (errno: %i)", errno); 
    738738        return NULL; 
    739739    } 
     
    746746    in = fopen(path,"r"); 
    747747    if (!in) { 
    748         GB_export_error("GB_map_file: sorry file '%s' not readable",path); 
     748        GB_export_errorf("GB_map_file: sorry file '%s' not readable",path); 
    749749        return NULL; 
    750750    } 
     
    12451245    } 
    12461246    else if (strlen(anypath) >= PATH_MAX) { 
    1247         GB_export_error("Path too long (> %i chars)", PATH_MAX-1); 
     1247        GB_export_errorf("Path too long (> %i chars)", PATH_MAX-1); 
    12481248    } 
    12491249    else { 
  • trunk/ARBDB/adstring.c

    r6099 r6100  
    5656    dirp = opendir(fulldir); 
    5757    if (!dirp){ 
    58         GB_ERROR error = GB_export_error("Directory %s of file %s.arb not readable",fulldir,file); 
     58        GB_ERROR error = GB_export_errorf("Directory %s of file %s.arb not readable",fulldir,file); 
    5959        free(path); 
    6060        return error; 
     
    211211 *  
    212212 * GB_export_error() shall only export, not return the error message. 
    213  * if only used for formatting GBS_global_string shall be used. 
     213 * if only used for formatting GBS_global_string shall be used 
     214 * (most cases where GB_export_errorf is used are candidates for this. 
     215 *  GB_export_error was generally misused for this, before 
     216 *  GBS_global_string was added!) 
    214217 * 
    215218 * GB_export_IO_error() shall not export and be renamed into GB_IO_error() 
     
    224227static char *GB_error_buffer = 0; 
    225228 
    226 GB_ERROR GB_export_error(const char *templat, ...) { 
    227     /* goes to header: __ATTR__FORMAT(1) */ 
     229GB_ERROR GB_export_error(const char *error) { // just a temp hack around format-warnings 
     230    return GB_export_errorf("%s", error); 
     231} 
     232 
     233GB_ERROR GB_export_errorf(const char *templat, ...) { 
     234    /* goes to header: __ATTR__FORMAT(1) __ATTR__DEPRECATED */ 
    228235 
    229236    char     buffer[GBS_GLOBAL_STRING_SIZE]; 
    230     char    *p  = buffer; 
     237    char    *p = buffer; 
    231238    va_list  parg; 
     239     
    232240    memset(buffer,0,1000); 
     241 
    233242#if defined(DEVEL_RALF) 
    234 #warning dont prepend error here     
     243#warning dont prepend error here 
    235244#endif /* DEVEL_RALF */ 
    236     sprintf (buffer,"ARB ERROR: "); 
    237     p          += strlen(p); 
     245 
     246    p += sprintf(buffer,"ARB ERROR: "); 
    238247    va_start(parg,templat); 
    239248 
     
    568577    if (!key || key[0] == 0) return GB_export_error("Empty key is not allowed"); 
    569578    len = strlen(key); 
    570     if (len>GB_KEY_LEN_MAX) return GB_export_error("Invalid key '%s': too long",key); 
    571     if (len < GB_KEY_LEN_MIN) return GB_export_error("Invalid key '%s': too short",key); 
     579    if (len>GB_KEY_LEN_MAX) return GB_export_errorf("Invalid key '%s': too long",key); 
     580    if (len < GB_KEY_LEN_MIN) return GB_export_errorf("Invalid key '%s': too short",key); 
    572581 
    573582    for (i = 0; key[i]; ++i) { 
     
    577586        if ( (c>='0') && (c<='9')) continue; 
    578587        if ( (c=='_') ) continue; 
    579         return GB_export_error("Invalid character '%c' in '%s'; allowed: a-z A-Z 0-9 '_' ", c, key); 
     588        return GB_export_errorf("Invalid character '%c' in '%s'; allowed: a-z A-Z 0-9 '_' ", c, key); 
    580589    } 
    581590 
     
    589598    if (!key || key[0] == 0) return GB_export_error("Empty key is not allowed"); 
    590599    len = strlen(key); 
    591     if (len>GB_KEY_LEN_MAX) return GB_export_error("Invalid key '%s': too long",key); 
    592     if (len < 1) return GB_export_error("Invalid key '%s': too short",key); // here it differs from GB_check_key 
     600    if (len>GB_KEY_LEN_MAX) return GB_export_errorf("Invalid key '%s': too long",key); 
     601    if (len < 1) return GB_export_errorf("Invalid key '%s': too short",key); // here it differs from GB_check_key 
    593602 
    594603    for (i = 0; key[i]; ++i) { 
     
    598607        if ( (c>='0') && (c<='9')) continue; 
    599608        if ( (c=='_') ) continue; 
    600         return GB_export_error("Invalid character '%c' in '%s'; allowed: a-z A-Z 0-9 '_' ", c, key); 
     609        return GB_export_errorf("Invalid character '%c' in '%s'; allowed: a-z A-Z 0-9 '_' ", c, key); 
    601610    } 
    602611 
     
    631640                if (c == '-') { 
    632641                    if (key_end[1] != '>') { 
    633                         err = GB_export_error("'>' expected after '-' in '%s'", key); 
     642                        err = GB_export_errorf("'>' expected after '-' in '%s'", key); 
    634643                    } 
    635644                    start = key_end+2; 
     
    10861095            } 
    10871096 
    1088             if (!names) GB_export_error("can't read directory '%s'", fulldir); 
     1097            if (!names) GB_export_errorf("can't read directory '%s'", fulldir); 
    10891098        } 
    10901099    } 
  • trunk/ARBDB/adtables.c

    r5525 r6100  
    4141    sep = strchr(link,':'); 
    4242    if (!sep){ 
    43         GB_export_error("Link '%s' is missing second ':' tag", link); 
     43        GB_export_errorf("Link '%s' is missing second ':' tag", link); 
    4444        return NULL; 
    4545    } 
     
    5050 
    5151    if (!gb_table){ 
    52         GB_export_error("Table '%s' does not exist",link); 
     52        GB_export_errorf("Table '%s' does not exist",link); 
    5353        return NULL; 
    5454    } 
     
    202202    GB_TYPES type = GBT_get_type_of_table_entry_field(gb_table,fieldname); 
    203203    if (type == GB_NONE){ 
    204         return GB_export_error("There is no field description '%s' for your table", fieldname); 
     204        return GB_export_errorf("There is no field description '%s' for your table", fieldname); 
    205205    } 
    206206    gb_entry_field = GB_search(gb_entry,"fieldname",type); 
  • trunk/ARBDB/adtools.c

    r6055 r6100  
    6565    if (strchr(name,':')) return 0; 
    6666    in = fopen(name,"r"); 
    67     if (!in) return GB_export_error("Cannot find file '%s'",name); 
     67    if (!in) return GB_export_errorf("Cannot find file '%s'",name); 
    6868    i = gb_read_in_long(in, 0); 
    6969    if ( (i== 0x56430176) || (i == GBTUM_MAGIC_NUMBER) || (i == GBTUM_MAGIC_REVERSED)) { 
     
    7979 
    8080 
    81     return GB_export_error("'%s' is not an arb file",name); 
     81    return GB_export_errorf("'%s' is not an arb file",name); 
    8282} 
    8383 
  • trunk/ARBDB/adtree.c

    r6065 r6100  
    625625 
    626626    gb_assert(error); 
    627     GB_export_error("Couldn't read tree '%s' (Reason: %s)", tree_name, error); 
     627    GB_export_errorf("Couldn't read tree '%s' (Reason: %s)", tree_name, error); 
    628628    return NULL; 
    629629} 
     
    801801     
    802802    if (!gb_tree) { 
    803         GB_export_error("tree '%s' not found",tree_name); 
     803        GB_export_errorf("tree '%s' not found",tree_name); 
    804804    } 
    805805    else { 
    806806        GBDATA *gb_nnodes = GB_entry(gb_tree,"nnodes"); 
    807807        if (!gb_nnodes) { 
    808             GB_export_error("nnodes not found in tree '%s'",tree_name); 
     808            GB_export_errorf("nnodes not found in tree '%s'",tree_name); 
    809809        } 
    810810        else { 
     
    842842    if ( (error = GB_check_key(tree_name)) ) return error; 
    843843    if (strncmp(tree_name,"tree_",5)){ 
    844         return GB_export_error("your treename '%s' does not begin with 'tree_'",tree_name); 
     844        return GB_export_errorf("your treename '%s' does not begin with 'tree_'",tree_name); 
    845845    } 
    846846    return 0; 
  • trunk/ARBDB/arbdb.c

    r6099 r6100  
    984984        case GB_FLOAT:  return GB_write_float(gbd,GB_atof(val)); 
    985985        case GB_BITS:   return GB_write_bits(gbd,val,strlen(val),"0"); 
    986         default:    return GB_export_error("Error: You cannot use GB_write_as_string on this type of entry (%s)",GB_read_key_pntr(gbd)); 
     986        default:    return GB_export_errorf("Error: You cannot use GB_write_as_string on this type of entry (%s)",GB_read_key_pntr(gbd)); 
    987987    } 
    988988} 
     
    10121012GB_ERROR gb_security_error(GBDATA *gbd){ 
    10131013    GB_MAIN_TYPE *Main = GB_MAIN(gbd); 
    1014     const char *error  = GB_export_error("Protection: Attempt to change a level-%i-'%s'-entry, \n" 
    1015                                          "but your current security level is only %i", 
    1016                                          GB_GET_SECURITY_WRITE(gbd), 
    1017                                          GB_read_key_pntr(gbd), 
    1018                                          Main->security_level); 
     1014    const char *error  = GB_export_errorf("Protection: Attempt to change a level-%i-'%s'-entry, \n" 
     1015                                          "but your current security level is only %i", 
     1016                                          GB_GET_SECURITY_WRITE(gbd), 
     1017                                          GB_read_key_pntr(gbd), 
     1018                                          Main->security_level); 
    10191019 
    10201020#if defined(DEBUG) 
     
    12971297    GB_TEST_TRANSACTION(father); 
    12981298    if ( GB_TYPE(father)!=GB_DB) { 
    1299         GB_export_error("GB_create: father (%s) is not of GB_DB type (%i) (creating '%s')", 
    1300                         GB_read_key_pntr(father),GB_TYPE(father),key); 
     1299        GB_export_errorf("GB_create: father (%s) is not of GB_DB type (%i) (creating '%s')", 
     1300                         GB_read_key_pntr(father),GB_TYPE(father),key); 
    13011301        return NULL; 
    13021302    }; 
     
    13301330    GB_TEST_TRANSACTION(father); 
    13311331    if ( GB_TYPE(father)!=GB_DB) { 
    1332         GB_export_error("GB_create: father (%s) is not of GB_DB type (%i) (creating '%s')", 
    1333                         GB_read_key_pntr(father),GB_TYPE(father),key); 
     1332        GB_export_errorf("GB_create: father (%s) is not of GB_DB type (%i) (creating '%s')", 
     1333                         GB_read_key_pntr(father),GB_TYPE(father),key); 
    13341334        return NULL; 
    13351335    }; 
     
    13491349    GB_TEST_TRANSACTION(source); 
    13501350    if (GB_GET_SECURITY_DELETE(source)>GB_MAIN(source)->security_level) { 
    1351         return GB_export_error("Security error in GB_delete: %s",GB_read_key_pntr(source)); 
     1351        return GB_export_errorf("Security error in GB_delete: %s",GB_read_key_pntr(source)); 
    13521352    } 
    13531353 
     
    14121412    if (GB_TYPE(dest) != type) 
    14131413    { 
    1414         return GB_export_error("incompatible types in GB_copy (source %s:%u != %s:%u", 
    1415                                GB_read_key_pntr(source), type, GB_read_key_pntr(dest), GB_TYPE(dest)); 
     1414        return GB_export_errorf("incompatible types in GB_copy (source %s:%u != %s:%u", 
     1415                                GB_read_key_pntr(source), type, GB_read_key_pntr(dest), GB_TYPE(dest)); 
    14161416    } 
    14171417 
     
    14511451            if (GB_TYPE(destc) != GB_DB) 
    14521452            { 
    1453                 GB_ERROR err = GB_export_error("GB_COPY Type conflict %s:%i != %s:%i", 
    1454                                                GB_read_key_pntr(dest), GB_TYPE(dest), GB_read_key_pntr(source), GB_DB); 
     1453                GB_ERROR err = GB_export_errorf("GB_COPY Type conflict %s:%i != %s:%i", 
     1454                                                GB_read_key_pntr(dest), GB_TYPE(dest), GB_read_key_pntr(source), GB_DB); 
    14551455                GB_internal_error(err); 
    14561456                return err; 
     
    16261626    GB_TEST_TRANSACTION(gbd); 
    16271627    if (GB_GET_SECURITY_DELETE(gbd)>GB_MAIN(gbd)->security_level) 
    1628         return GB_export_error("Security error in GB_set_temporary: %s",GB_read_key_pntr(gbd)); 
     1628        return GB_export_errorf("Security error in GB_set_temporary: %s",GB_read_key_pntr(gbd)); 
    16291629    gbd->flags.temporary = 1; 
    16301630    gb_touch_entry(gbd,gb_changed); 
     
    17311731    gbd                = (GBDATA *)Main->data; 
    17321732    if (Main->transaction>0) { 
    1733         error = GB_export_error("GB_begin_transaction called %i !!!", 
    1734                                 Main->transaction); 
     1733        error = GB_export_errorf("GB_begin_transaction called %i !!!", 
     1734                                 Main->transaction); 
    17351735        GB_internal_error(error); 
    17361736        return GB_push_transaction(gbd); 
     
    22752275    } 
    22762276    if (GB_TYPE(gbd) != GB_DB) { 
    2277         GB_ERROR error=GB_export_error("You cannot release non container (%s)", 
    2278                                        GB_read_key_pntr(gbd)); 
     2277        GB_ERROR error = GB_export_errorf("You cannot release non container (%s)", 
     2278                                          GB_read_key_pntr(gbd)); 
    22792279        GB_internal_error(error); 
    22802280        return error; 
     
    23362336 
    23372337    if (GB_read_clients(gb_main)>0) 
    2338         return GB_export_error("There are %li clients (editors, tree programms) connected to this server,\n" 
    2339                                "please close clients and rerun operation", 
    2340                                GB_read_clients(gb_main)); 
     2338        return GB_export_errorf("There are %li clients (editors, tree programms) connected to this server,\n" 
     2339                                "please close clients and rerun operation", 
     2340                                GB_read_clients(gb_main)); 
    23412341 
    23422342    if (listsize <=0) return 0; 
     
    24272427    GBCONTAINER *gbc = (GBCONTAINER *)gbd; 
    24282428    if (GB_TYPE(gbc) != GB_DB) { 
    2429         GB_ERROR error = GB_export_error("GB_write_usr_private: not a container (%s)",GB_read_key_pntr(gbd)); 
     2429        GB_ERROR error = GB_export_errorf("GB_write_usr_private: not a container (%s)",GB_read_key_pntr(gbd)); 
    24302430        GB_internal_error(error); 
    24312431        return 0; 
     
    24372437    GBCONTAINER *gbc = (GBCONTAINER *)gbd; 
    24382438    if (GB_TYPE(gbc) != GB_DB) { 
    2439         GB_ERROR error = GB_export_error("GB_write_usr_private: not a container (%s)",GB_read_key_pntr(gbd)); 
     2439        GB_ERROR error = GB_export_errorf("GB_write_usr_private: not a container (%s)",GB_read_key_pntr(gbd)); 
    24402440        GB_internal_error(error); 
    24412441        return 0; 
  • trunk/AWT/AWT_csp.cxx

    r5968 r6100  
    8282    GB_ERROR error = 0; 
    8383    if (alignment_length <= 1) 
    84         return GB_export_error( "Unknown Alignment Size: Name '%s'\n" 
     84        return GB_export_errorf("Unknown Alignment Size: Name '%s'\n" 
    8585                                "   Select a Valid Alignment",alignment_name); 
    8686    if (filter && filter->filter_len != alignment_length) 
  • trunk/AWT/AWT_input_mask.cxx

    r6034 r6100  
    144144GB_ERROR awt_input_mask_id_list::add(const string& name, awt_mask_item *item) { 
    145145    awt_mask_item *existing = lookup(name); 
    146     if (existing) return GB_export_error("ID '%s' already exists", name.c_str()); 
     146    if (existing) return GB_export_errorf("ID '%s' already exists", name.c_str()); 
    147147 
    148148    id[name] = item; 
     
    150150} 
    151151GB_ERROR awt_input_mask_id_list::remove(const string& name) { 
    152     if (!lookup(name)) return GB_export_error("ID '%s' does not exist", name.c_str()); 
     152    if (!lookup(name)) return GB_export_errorf("ID '%s' does not exist", name.c_str()); 
    153153    id.erase(name); 
    154154    return 0; 
     
    168168    GB_ERROR error = 0; 
    169169    if (has_name()) { 
    170         error = GB_export_error("Element already has name (%s)", get_name().c_str()); 
     170        error = GB_export_errorf("Element already has name (%s)", get_name().c_str()); 
    171171    } 
    172172    else { 
     
    16641664 
    16651665                                    if ((cmd == CMD_GLOBAL && local_exists) || (cmd == CMD_LOCAL && global_exists)) { 
    1666                                         error = GB_export_error("ID '%s' already declared as %s ID (rename your local id)", 
    1667                                                                 id.c_str(), cmd == CMD_LOCAL ? "global" : "local"); 
     1666                                        error = GB_export_errorf("ID '%s' already declared as %s ID (rename your local id)", 
     1667                                                                 id.c_str(), cmd == CMD_LOCAL ? "global" : "local"); 
    16681668                                    } 
    16691669                                    else if (cmd == CMD_LOCAL && local_exists) { 
    1670                                         error = GB_export_error("ID '%s' declared twice", id.c_str()); 
     1670                                        error = GB_export_errorf("ID '%s' declared twice", id.c_str()); 
    16711671                                    } 
    16721672 
     
    18991899                for (map<string, size_t>::const_iterator r = referenced_ids.begin(); r != referenced_ids.end(); ++r) { 
    19001900                    if (declared_ids.find(r->first) == declared_ids.end()) { 
    1901                         error = GB_export_error("ID '%s' used in line #%zu was not declared", r->first.c_str(), r->second); 
     1901                        error = GB_export_errorf("ID '%s' used in line #%zu was not declared", r->first.c_str(), r->second); 
    19021902                        aw_message(error); 
    19031903                    } 
  • trunk/AWT/AWT_nds.cxx

    r5963 r6100  
    362362                } 
    363363                else { 
    364                     error = GB_export_error("Expected entry '%s' in saved config", inherit_key); 
     364                    error = GB_export_errorf("Expected entry '%s' in saved config", inherit_key); 
    365365                } 
    366366            } 
     
    398398                } 
    399399                else { 
    400                     error = GB_export_error("Expected entry '%s' in saved config", flag1_key); 
     400                    error = GB_export_errorf("Expected entry '%s' in saved config", flag1_key); 
    401401                } 
    402402            } 
  • trunk/AWT/AWT_query_and_functions.cxx

    r5999 r6100  
    23332333                            else { 
    23342334                                char *name = GBT_read_string(gb_item,"name"); 
    2335                                 error = GB_export_error("Field '%s' of %s '%s' has incombatible type", key, cbs->selector->item_name, name); 
     2335                                error = GB_export_errorf("Field '%s' of %s '%s' has incombatible type", key, cbs->selector->item_name, name); 
    23362336                                free(name); 
    23372337                            } 
  • trunk/AWT/AWT_seq_colors.cxx

    r5928 r6100  
    200200            char *val = GBT_read_string(gb_def,buf); 
    201201            if (strlen(val) != 2 || val[1] >'9' || val[1] < '0'){ 
    202                 aw_message(GB_export_error("Error in Color Lookup Table: '%s' is not of type X#",val)); 
     202                aw_message(GB_export_errorf("Error in Color Lookup Table: '%s' is not of type X#",val)); 
    203203                delete val; 
    204204                delete sc; 
  • trunk/AWT/AWT_tree.cxx

    r5925 r6100  
    11371137    else if (new_group->is_leaf) { 
    11381138        if (new_group->name) { 
    1139             error = GB_export_error("'%s' is not a valid target for group information of '%s'.", new_group->name, name); 
     1139            error = GB_export_errorf("'%s' is not a valid target for group information of '%s'.", new_group->name, name); 
    11401140        } 
    11411141        else if (new_group->gb_node) { 
  • trunk/AWT/AWT_www.cxx

    r5842 r6100  
    111111 
    112112    if (!gb_species){ 
    113         error = GB_export_error("Cannot find species '%s'",selected_species); 
     113        error = GB_export_errorf("Cannot find species '%s'",selected_species); 
    114114    }else{ 
    115115        error = awt_openURL_by_gbd(aw_root,gb_main, gb_species, selected_species); 
  • trunk/AWT/awt_input_mask_internal.hxx

    r6031 r6100  
    125125 
    126126    GB_ERROR add_local_id(const std::string& name, awt_mask_item *handler) { 
    127         if (has_global_id(name)) return GB_export_error("ID '%s' already defined as GLOBAL", name.c_str()); 
     127        if (has_global_id(name)) return GB_export_errorf("ID '%s' already defined as GLOBAL", name.c_str()); 
    128128        return ids.add(name, handler); 
    129129    } 
    130130 
    131131    GB_ERROR add_global_id(const std::string& name, awt_mask_item *handler) { 
    132         if (has_local_id(name)) return GB_export_error("ID '%s' already defined as LOCAL", name.c_str()); 
     132        if (has_local_id(name)) return GB_export_errorf("ID '%s' already defined as LOCAL", name.c_str()); 
    133133        return global_ids.add(name, handler); 
    134134    } 
     
    147147            found             = ids.lookup(name); 
    148148            if (!found) found = global_ids.lookup(name); 
    149             if (!found) error = GB_export_error("No item '%s' declared", name.c_str()); 
     149            if (!found) error = GB_export_errorf("No item '%s' declared", name.c_str()); 
    150150        } 
    151151        return found; 
  • trunk/AWTI/AWTI_import.cxx

    r6096 r6100  
    789789                char *file = 0; 
    790790                if (awtcig.current_file[0]) file = awtcig.current_file[0]; 
    791                 GB_ERROR msg = GB_export_error("A database entry in file '%s' is longer than %i lines.\n" 
    792                                                "    This might be the result of a wrong input format\n" 
    793                                                "    or a long comment in a sequence\n",file,line); 
     791                GB_ERROR msg = GB_export_errorf("A database entry in file '%s' is longer than %i lines.\n" 
     792                                                "    This might be the result of a wrong input format\n" 
     793                                                "    or a long comment in a sequence\n",file,line); 
    794794 
    795795                switch (aw_question(msg,"Continue Reading,Continue Reading (Never ask again),Abort"))  { 
     
    889889            if (!p) break; 
    890890        } 
    891         return GB_export_error("No Start of Sequence found (%i lines read)", max_line); 
     891        return GB_export_errorf("No Start of Sequence found (%i lines read)", max_line); 
    892892 
    893893    read_sequence: 
  • trunk/DIST/DI_matr.cxx

    r6065 r6100  
    314314                if (!gb_species) { 
    315315                    if (show_warnings) { 
    316                         aw_message(GB_export_error("Species '%s' found in tree '%s' but NOT in database.", 
    317                                                    species_in_sort_tree[i], sort_tree_name)); 
     316                        aw_message(GB_export_errorf("Species '%s' found in tree '%s' but NOT in database.", 
     317                                                    species_in_sort_tree[i], sort_tree_name)); 
    318318                    } 
    319319                    unknown_species_in_tree++; 
     
    355355 
    356356    if (unknown_species_in_tree && show_warnings) { 
    357         aw_message(GB_export_error("We found %i species in tree '%s' which are not in database.\n" 
    358                                    "This does not affect the current calculation, but you should think about it.", 
    359                                    unknown_species_in_tree, sort_tree_name)); 
     357        aw_message(GB_export_errorf("We found %i species in tree '%s' which are not in database.\n" 
     358                                    "This does not affect the current calculation, but you should think about it.", 
     359                                    unknown_species_in_tree, sort_tree_name)); 
    360360    } 
    361361 
  • trunk/DIST/DI_mldist.cxx

    r5392 r6100  
    266266                        tt -= slope / curv; 
    267267                        if (tt > 10000.0) { 
    268                             aw_message(GB_export_error("INFINITE DISTANCE BETWEEN SPECIES %ld AND %ld; -1.0 WAS WRITTEN\n", i, j)); 
     268                            aw_message(GB_export_errorf("INFINITE DISTANCE BETWEEN SPECIES %ld AND %ld; -1.0 WAS WRITTEN\n", i, j)); 
    269269                            tt = -1.0 / fracchange; 
    270270                            break; 
  • trunk/DIST/DI_protdist.cxx

    r5708 r6100  
    715715                            tt -= slope / curv; 
    716716                            if (tt > 10000.0) { 
    717                                 aw_message(GB_export_error("INFINITE DISTANCE BETWEEN SPECIES %ld AND %ld; -1.0 WAS WRITTEN\n", i, j)); 
     717                                aw_message(GB_export_errorf("INFINITE DISTANCE BETWEEN SPECIES %ld AND %ld; -1.0 WAS WRITTEN\n", i, j)); 
    718718                                tt = -1.0 / fracchange; 
    719719                                break; 
     
    761761                                double drel = 1.0 - rel - 0.2 * rel * rel; 
    762762                                if (drel < 0.0) { 
    763                                     aw_message(GB_export_error("DISTANCE BETWEEN SEQUENCES %3ld AND %3ld IS TOO LARGE FOR KIMURA FORMULA", i, j)); 
     763                                    aw_message(GB_export_errorf("DISTANCE BETWEEN SEQUENCES %3ld AND %3ld IS TOO LARGE FOR KIMURA FORMULA", i, j)); 
    764764                                    tt = -1.0; 
    765765                                }else{ 
  • trunk/EDIT/edit.cxx

    r6069 r6100  
    445445            default: 
    446446                if (does_species_exists(spname)) { 
    447                     if (do_what == 1) error = GB_export_error("Species %s already exists",spname); 
     447                    if (do_what == 1) error = GB_export_errorf("Species %s already exists",spname); 
    448448                }else{ 
    449                     if (do_what == 0) error = GB_export_error("Cannot find species %s",spname); 
     449                    if (do_what == 0) error = GB_export_errorf("Cannot find species %s",spname); 
    450450                } 
    451451        } 
  • trunk/EDIT4/ED4_ProteinViewer.cxx

    r5943 r6100  
    604604                startPos4Translation = atoi(GB_read_char_pntr(gb_codonStart))-1; 
    605605                if (startPos4Translation<0 || startPos4Translation>2) { 
    606                     error = GB_export_error("'%s' has invalid codon_start entry %i (allowed: 1..3)", 
    607                                             speciesName, startPos4Translation+1); 
     606                    error = GB_export_errorf("'%s' has invalid codon_start entry %i (allowed: 1..3)", 
     607                                             speciesName, startPos4Translation+1); 
    608608                    break; 
    609609                } 
  • trunk/EDIT4/ED4_no_class.cxx

    r6033 r6100  
    12541254        } 
    12551255        else if (!foundField) { 
    1256             error = GB_export_error("Field not found: '%s'", field_name); 
     1256            error = GB_export_errorf("Field not found: '%s'", field_name); 
    12571257        } 
    12581258    } 
     
    17871787    } 
    17881788    else { 
    1789         error = GB_export_error("Can't find alignment '%s'", ali); 
     1789        error = GB_export_errorf("Can't find alignment '%s'", ali); 
    17901790    } 
    17911791    free(consensus); 
  • trunk/EDIT4/ED4_protein_2nd_structure.cxx

    r5829 r6100  
    10031003        if (protstruct_len) protstruct_len = 0; 
    10041004        if (aw_root->awar(PFOLD_AWAR_ENABLE)->read_int()) { 
    1005             error = GB_export_error( "SAI \"%s\" does not exist.\nDisabled protein structure display!", SAI_name ); 
     1005            error = GB_export_errorf( "SAI \"%s\" does not exist.\nDisabled protein structure display!", SAI_name ); 
    10061006            aw_root->awar(PFOLD_AWAR_ENABLE)->write_int(0); 
    10071007        } 
  • trunk/GENOM/EXP_interface.cxx

    r6007 r6100  
    295295 
    296296            if (gb_dest) { 
    297                 error  = GB_export_error("Experiment '%s' already exists", dest); 
     297                error  = GB_export_errorf("Experiment '%s' already exists", dest); 
    298298            } 
    299299            else { 
     
    326326 
    327327                if (!gb_source) error   = "Please select an experiment"; 
    328                 else if (gb_dest) error = GB_export_error("Experiment '%s' already exists", dest); 
     328                else if (gb_dest) error = GB_export_errorf("Experiment '%s' already exists", dest); 
    329329                else { 
    330330                    GBDATA *gb_name     = GB_search(gb_source, "name", GB_STRING); 
     
    361361 
    362362            if (!gb_source) error   = "Please select a experiment"; 
    363             else if (gb_dest) error = GB_export_error("Experiment '%s' already exists", dest); 
     363            else if (gb_dest) error = GB_export_errorf("Experiment '%s' already exists", dest); 
    364364            else { 
    365365                gb_dest             = GB_create_container(gb_experiment_data,"experiment"); 
  • trunk/GENOM/GEN_interface.cxx

    r6007 r6100  
    359359 
    360360                if (!gb_source) error   = "Please select a gene first"; 
    361                 else if (gb_dest) error = GB_export_error("Gene '%s' already exists", dest); 
     361                else if (gb_dest) error = GB_export_errorf("Gene '%s' already exists", dest); 
    362362                else { 
    363363                    GBDATA *gb_name = GB_search(gb_source, "name", GB_STRING); 
     
    417417 
    418418            if (!gb_source) error   = "Please select a gene"; 
    419             else if (gb_dest) error = GB_export_error("Gene '%s' already exists", dest); 
     419            else if (gb_dest) error = GB_export_errorf("Gene '%s' already exists", dest); 
    420420            else { 
    421421                gb_dest             = GB_create_container(gb_gene_data,"gene"); 
  • trunk/GENOM/GEN_map.cxx

    r6072 r6100  
    684684    else { // key exists 
    685685        if (GB_read_type(gbd) != GB_STRING) { // test correct key type 
    686             error = GB_export_error("field '%s' exists and has wrong type", key); 
     686            error = GB_export_errorf("field '%s' exists and has wrong type", key); 
    687687        } 
    688688    } 
     
    871871                    gen_assert(short_name); 
    872872                    gb_exist_geneSpec = GBT_find_or_create_species(GLOBAL_gb_main, short_name); 
    873                     if (!gb_exist_geneSpec) error = GB_export_error("Failed to create pseudo-species '%s'", short_name); 
     873                    if (!gb_exist_geneSpec) error = GB_export_errorf("Failed to create pseudo-species '%s'", short_name); 
    874874                    else eg2ps->existing.add_name(short_name); 
    875875                } 
  • trunk/MERGE/MG_gene_species.cxx

    r5944 r6100  
    272272        GBDATA         *gb_species = GBT_find_species(GLOBAL_gb_merge, curr_species); 
    273273 
    274         if (!gb_species)                                    error = GB_export_error("No such species: '%s'", curr_species); 
     274        if (!gb_species)                                    error = GB_export_errorf("No such species: '%s'", curr_species); 
    275275        else if (!GEN_is_pseudo_gene_species(gb_species))   error = "Selected species is no gene-species"; 
    276276        else { 
  • trunk/MERGE/MG_preserves.cxx

    r5852 r6100  
    125125        } 
    126126        default: 
    127             GB_export_error("Data type %s is not supported", GB_get_type_name(gb_data)); 
     127            GB_export_errorf("Data type %s is not supported", GB_get_type_name(gb_data)); 
    128128            break; 
    129129    } 
  • trunk/MERGE/MG_species.cxx

    r6077 r6100  
    10011001        switch (d) { 
    10021002            case 0: 
    1003                 error = GB_export_error("Cannot find a target alignment with a type of '%s'\n" 
    1004                                         "You should create one first or select a different alignment type\n" 
    1005                                         "during sequence import",type); 
     1003                error = GB_export_errorf("Cannot find a target alignment with a type of '%s'\n" 
     1004                                         "You should create one first or select a different alignment type\n" 
     1005                                         "during sequence import",type); 
    10061006                break; 
    10071007            case 1: 
  • trunk/NTREE/AP_consensus.cxx

    r5825 r6100  
    609609 
    610610    long maxalignlen = GBT_get_alignment_len(GLOBAL_gb_main,align); 
    611     if (maxalignlen <= 0) error = GB_export_error("alignment '%s' doesn't exist", align); 
     611    if (maxalignlen <= 0) error = GB_export_errorf("alignment '%s' doesn't exist", align); 
    612612 
    613613    if (!error) { 
  • trunk/NTREE/AP_csp_2_gnuplot.cxx

    r5851 r6100  
    4141 
    4242    const char *lslash = strrchr(fname, '/'); 
    43     if (!lslash) return GB_export_error("'%s' has to contain a '/'", fname); 
     43    if (!lslash) return GB_export_errorf("'%s' has to contain a '/'", fname); 
    4444 
    4545    char *dir         = strdup(fname); 
     
    270270            if (!error) { 
    271271                out = fopen(fname,"w"); 
    272                 if (!out) error = GB_export_error("Cannot write to file '%s'",fname); 
     272                if (!out) error = GB_export_errorf("Cannot write to file '%s'",fname); 
    273273            } 
    274274 
  • trunk/NTREE/NT_concatenate.cxx

    r5978 r6100  
    666666                    if (!error) id += GBS_checksum(seq_data,1,".-");  //creating checksum of the each aligned sequence to generate new accession number 
    667667                } 
    668                 if (error) error = GB_export_error("Can't create alignment '%s'", ali_names[no_of_alignments]); 
     668                if (error) error = GB_export_errorf("Can't create alignment '%s'", ali_names[no_of_alignments]); 
    669669            } 
    670670        } 
  • trunk/PARSIMONY/AP_tree_edge.cxx

    r5725 r6100  
    579579        int diff = ne[i] - old[i]; 
    580580        if (diff > 1 || diff < -1){ 
    581             GB_export_error("shit shit shit, diff by nni at one position not in [-1,1]: %i:%i - %i",diff,old[i],ne[i]); 
     581            GB_export_errorf("diff by nni at one position not in [-1,1]: %i:%i - %i",diff,old[i],ne[i]); 
    582582            GB_print_error(); 
    583583            continue; 
  • trunk/PARSIMONY/PARS_main.cxx

    r6072 r6100  
    18731873            continue; 
    18741874        } 
    1875         GB_export_error("Unknown option '%s'",argv[0]); 
     1875        GB_export_errorf("Unknown option '%s'",argv[0]); 
    18761876        GB_print_error(); 
    18771877        printf("    Options:                Meaning:\n" 
  • trunk/PERL2ARB/ARB_ext.c

    r5928 r6100  
    6060    if (!arg){ 
    6161        free(data); 
    62         return GB_export_error("Sorry: You never installed a callback '%s:%s'",perl_func,perl_cl); 
     62        return GB_export_errorf("Sorry: You never installed a callback '%s:%s'",perl_func,perl_cl); 
    6363    }else{ 
    6464        GBS_write_hash(gbp_cp_hash_table,data,0); 
  • trunk/PRIMER_DESIGN/primer_design.cxx

    r5943 r6100  
    298298        gb_seq                = GBT_read_sequence( gb_species, alignment ); 
    299299        if (!gb_seq) { 
    300             error = GB_export_error("Species '%s' has no data in alignment '%s'", selected_species, alignment); 
     300            error = GB_export_errorf("Species '%s' has no data in alignment '%s'", selected_species, alignment); 
    301301        } 
    302302    } 
     
    307307        gb_gene = GEN_find_gene(gb_species, selected_gene); 
    308308        if (!gb_gene) { 
    309             error = GB_export_error("Species '%s' has no gene named '%s'", selected_species, selected_gene); 
     309            error = GB_export_errorf("Species '%s' has no gene named '%s'", selected_species, selected_gene); 
    310310        } 
    311311        else { 
  • trunk/PROBE_DESIGN/probe_design.cxx

    r5981 r6100  
    513513                    GBDATA *data = GBT_read_sequence(gb_species,ali_name); 
    514514                    if (!data) { 
    515                         aw_message( GB_export_error("Species '%s' has no sequence belonging to alignment '%s'", unames, ali_name)); 
     515                        aw_message( GB_export_errorf("Species '%s' has no sequence belonging to alignment '%s'", unames, ali_name)); 
    516516                        abort = true; 
    517517                    } 
     
    14221422            int idx = i-'A'; 
    14231423            if (idx<0 || idx>=26 || AWT_iupac_code[idx][index].iupac==0) { 
    1424                 err = GB_export_error("Illegal character '%c' in IUPAC-String", i); 
     1424                err = GB_export_errorf("Illegal character '%c' in IUPAC-String", i); 
    14251425                break; 
    14261426            } 
     
    21002100 
    21012101        if (reason) { 
    2102             error = GB_export_error("Error in database format (reason: %s)", reason); 
     2102            error = GB_export_errorf("Error in database format (reason: %s)", reason); 
    21032103            aws->insert_selection(selList, error, (long)0); 
    21042104        } 
     
    21072107    } 
    21082108    else { 
    2109         error = GB_export_error("Can't open database '%s'", file_name); 
     2109        error = GB_export_errorf("Can't open database '%s'", file_name); 
    21102110        freeset(pg_global.pg_filename, 0); 
    21112111    } 
  • trunk/SECEDIT/SEC_graphic.cxx

    r6017 r6100  
    608608        GBDATA *gb_species = GBT_find_SAI(gb_main, name); 
    609609        if (!gb_species) { 
    610             err = GB_export_error("Cannot find helix template SAI '%s'",name); 
     610            err = GB_export_errorf("Cannot find helix template SAI '%s'",name); 
    611611        } 
    612612        else { 
     
    615615            ali_len = GBT_get_alignment_len(gb_main,ali_name); 
    616616            if (ali_len < 10) { 
    617                 err = GB_export_error("alignment '%s' to short to generate helix",ali_name); 
     617                err = GB_export_errorf("alignment '%s' to short to generate helix",ali_name); 
    618618            } 
    619619            else { 
    620620                gb_ali = GB_search(gb_species, ali_name, GB_FIND); 
    621621                if (!gb_ali) { 
    622                     err = GB_export_error("Your helix structure template '%s' has no valid sequence for alignment '%s'", name,ali_name); // no sequence for name in the database !!! 
     622                    err = GB_export_errorf("Your helix structure template '%s' has no valid sequence for alignment '%s'", name,ali_name); // no sequence for name in the database !!! 
    623623                } 
    624624            } 
  • trunk/SECEDIT/SEC_main.cxx

    r6017 r6100  
    304304    } 
    305305    else { 
    306         error = GB_export_error("Can't write secondary structure to '%s'", filename); 
     306        error = GB_export_errorf("Can't write secondary structure to '%s'", filename); 
    307307    } 
    308308 
     
    365365 
    366366        if (!in) { 
    367             error = GB_export_error("Can't open file '%s'", filename); 
     367            error = GB_export_errorf("Can't open file '%s'", filename); 
    368368        } 
    369369        else { 
  • trunk/SERVERCNTRL/servercntrl.c

    r6084 r6100  
    7878 
    7979    if (!(tcp_id = GBS_read_arb_tcp(arb_tcp_env))) { 
    80         error = GB_export_error("Entry '%s' in $(ARBHOME)/lib/arb_tcp.dat not found", arb_tcp_env); 
     80        error = GB_export_errorf("Entry '%s' in $(ARBHOME)/lib/arb_tcp.dat not found", arb_tcp_env); 
    8181    } 
    8282    else { 
     
    129129 
    130130                if (!port) { 
    131                     error = GB_export_error("Error: Missing ':' in line '%s' file $(ARBHOME)/lib/arb_tcp.dat", arb_tcp_env); 
     131                    error = GB_export_errorf("Error: Missing ':' in line '%s' file $(ARBHOME)/lib/arb_tcp.dat", arb_tcp_env); 
    132132                } 
    133133                else { 
     
    264264 
    265265    if (!(tcp_id = GBS_read_arb_tcp(arb_tcp_env))) { 
    266         error = GB_export_error("Missing line '%s' in $(ARBHOME)/lib/arb_tcp.dat:",arb_tcp_env); 
     266        error = GB_export_errorf("Missing line '%s' in $(ARBHOME)/lib/arb_tcp.dat:",arb_tcp_env); 
    267267    } 
    268268    else { 
     
    274274            /* sprintf(command, "%s -kill -T%s &", server, tcp_id); */ 
    275275            if (system(command)) { 
    276                 error = GB_export_error("Cannot execute '%s'",command); 
     276                error = GB_export_errorf("Cannot execute '%s'",command); 
    277277            } 
    278278            aisc_close(glservercntrl.link); 
  • trunk/SL/AW_NAME/AW_rename.cxx

    r6084 r6100  
    349349        } 
    350350        else { 
    351             err = GB_export_error("Generation of short name for '%s' failed", full_name); 
     351            err = GB_export_errorf("Generation of short name for '%s' failed", full_name); 
    352352        } 
    353353    } 
     
    679679 
    680680    gb_assert(!result || strlen(result) <= 8); 
    681     if (!result) GB_export_error("Failed to create unique shortname (prefix='%s')", prefix); 
     681    if (!result) GB_export_errorf("Failed to create unique shortname (prefix='%s')", prefix); 
    682682 
    683683    return result; 
  • trunk/SL/FAST_ALIGNER/fast_aligner.cxx

    r6083 r6100  
    133133 
    134134static inline GB_ERROR species_not_found(GB_CSTR species_name) { 
    135     return GB_export_error("No species '%s' found!", species_name); 
     135    return GB_export_errorf("No species '%s' found!", species_name); 
    136136} 
    137137 
     
    141141 
    142142    if (!gbd) { 
    143         error = GB_export_error("No 'data' found for species '%s'", GBT_read_name(gb_species)); 
     143        error = GB_export_errorf("No 'data' found for species '%s'", GBT_read_name(gb_species)); 
    144144    } 
    145145    else { 
     
    159159        } 
    160160        else { // protection error 
    161             error = GB_export_error("Cannot reverse-complement species '%s' because of protection level", GBT_read_name(gb_species)); 
     161            error = GB_export_errorf("Cannot reverse-complement species '%s' because of protection level", GBT_read_name(gb_species)); 
    162162        } 
    163163 
     
    11291129    } 
    11301130    else { 
    1131         error = GB_export_error("No 'data' found for species '%s'", GBT_read_name(gb_species)); 
     1131        error = GB_export_errorf("No 'data' found for species '%s'", GBT_read_name(gb_species)); 
    11321132        if (dataPtr) *dataPtr = NULL; // (user must not care to free data if we fail) 
    11331133    } 
     
    11501150    } 
    11511151    else { 
    1152         error = GB_export_error("Cannot create entry '%s' for '%s'", data_name, GBT_read_name(gb_species)); 
     1152        error = GB_export_errorf("Cannot create entry '%s' for '%s'", data_name, GBT_read_name(gb_species)); 
    11531153    } 
    11541154 
     
    14981498            GBDATA *gbd = GBT_read_sequence(gb_toAlign, relSearch.pt_server_alignment); // use a different alignment for next relative search 
    14991499            if (!gbd) { 
    1500                 error = GB_export_error("Species '%s' has no data in alignment '%s'", GBT_read_name(gb_toAlign), relSearch.pt_server_alignment); 
     1500                error = GB_export_errorf("Species '%s' has no data in alignment '%s'", GBT_read_name(gb_toAlign), relSearch.pt_server_alignment); 
    15011501            } 
    15021502            else { 
     
    22072207 
    22082208    if (wasNotAllowedToAlign>0) { 
    2209         const char *mess = GB_export_error("%i species were not aligned (because of protection level)", wasNotAllowedToAlign); 
     2209        const char *mess = GB_export_errorf("%i species were not aligned (because of protection level)", wasNotAllowedToAlign); 
    22102210        aw_popup_ok(mess); 
    22112211    } 
     
    22132213    if (err_count) { 
    22142214        if (error) aw_message(error); 
    2215         error = GB_export_error("Aligner produced %i error%c", err_count, err_count==1 ? '\0' : 's'); 
     2215        error = GB_export_errorf("Aligner produced %i error%c", err_count, err_count==1 ? '\0' : 's'); 
    22162216    } 
    22172217 
  • trunk/SL/TREE_READ/TreeRead.cxx

    r6030 r6100  
    475475    tree_assert(tree||error); 
    476476    if (error) { 
    477         GB_export_error("Import tree: %s", error); 
     477        GB_export_errorf("Import tree: %s", error); 
    478478        tree_assert(!tree); 
    479479    } 
  • trunk/SL/TREE_WRITE/TreeWrite.cxx

    r6066 r6100  
    225225    FILE     *output = fopen(path, "w"); 
    226226 
    227     if (!output) error = GB_export_error("file '%s' could not be opened for writing", path); 
     227    if (!output) error = GB_export_errorf("file '%s' could not be opened for writing", path); 
    228228    else { 
    229229        GB_transaction gb_dummy(gb_main); 
     
    303303    FILE     *output = fopen(path, "w"); 
    304304 
    305     if (!output) error = GB_export_error("file '%s' could not be opened for writing", path); 
     305    if (!output) error = GB_export_errorf("file '%s' could not be opened for writing", path); 
    306306    else { 
    307307        GB_transaction gb_dummy(gb_main); 
  • trunk/WINDOW/AW_nawar.cxx

    r6068 r6100  
    602602        if (!shown_name) shown_name = default_name; 
    603603 
    604         GBK_terminate(GBS_global_string("Error loading properties '%s': %s", shown_name, error)); 
     604        GBK_terminatef(GBS_global_string("Error loading properties '%s': %s", shown_name, error)); 
    605605    } 
    606606    return (AW_default) gb_default; 
  • trunk/WINDOW/AW_window.cxx

    r6072 r6100  
    34333433    char *macro_header = GB_read_file("$(ARBHOME)/lib/macro.head"); 
    34343434    if (!macro_header) { 
    3435         return GB_export_error("Cannot open file '%s'", "$(ARBHOME)/lib/macro.head"); 
     3435        return GB_export_errorf("Cannot open file '%s'", "$(ARBHOME)/lib/macro.head"); 
    34363436    } 
    34373437 
     
    34403440    if (!prvt->recording_macro_file) { 
    34413441        delete macro_header; 
    3442         return GB_export_error("Cannot open file '%s' for writing", file); 
     3442        return GB_export_errorf("Cannot open file '%s' for writing", file); 
    34433443    } 
    34443444    prvt->stop_action_name = strdup(stop_action_name); 
     
    34983498        if (!old_cbs->is_equal(*cbs)) {                  // existing remote command replaced by different callback 
    34993499#if defined(DEBUG) 
    3500             fprintf(stderr, GBS_global_string("Warning: duplicated use of callback id '%s'\n", old_cbs->id)); 
     3500            fputs(GBS_global_string("Warning: duplicated use of callback id '%s'\n", old_cbs->id), stderr); 
    35013501#if defined(DEVEL_RALF) 
    35023502            gb_assert(0); 
     
    35703570            GBT_write_string(gb_main, awar_result, ""); 
    35713571        } else { 
    3572             aw_message(GB_export_error("Unknown action '%s' in macro", action)); 
     3572            aw_message(GB_export_errorf("Unknown action '%s' in macro", action)); 
    35733573            GBT_write_string(gb_main, awar_result, GB_await_error()); 
    35743574        }