]> granicus.if.org Git - curl/commitdiff
unconditional progressbarinit cures a windows crash
authorDaniel Stenberg <daniel@haxx.se>
Wed, 19 Nov 2003 15:59:23 +0000 (15:59 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Wed, 19 Nov 2003 15:59:23 +0000 (15:59 +0000)
src/main.c

index 39ba0b2ef436c1d7ac59facfd23a0baddfcbf82c..be805ce1575d1e410a7db4d37217cc9387d93720 100644 (file)
@@ -3229,11 +3229,11 @@ operate(struct Configurable *config, int argc, char *argv[])
         curl_easy_setopt(curl, CURLOPT_INTERFACE, config->iface);
         curl_easy_setopt(curl, CURLOPT_KRB4LEVEL, config->krb4level);
       
+        progressbarinit(&progressbar, config);
         if((config->progressmode == CURL_PROGRESS_BAR) &&
            !(config->conf&(CONF_NOPROGRESS|CONF_MUTE))) {
           /* we want the alternative style, then we have to implement it
              ourselves! */
-          progressbarinit(&progressbar, config);
           curl_easy_setopt(curl, CURLOPT_PROGRESSFUNCTION, myprogress);
           curl_easy_setopt(curl, CURLOPT_PROGRESSDATA, &progressbar);
         }