~ubuntu-branches/ubuntu/saucy/edbrowse/saucy

« back to all changes in this revision

Viewing changes to src/main.c

  • Committer: Bazaar Package Importer
  • Author(s): Chris Coulson
  • Date: 2010-11-29 12:06:07 UTC
  • mfrom: (1.1.6 upstream)
  • Revision ID: james.westby@ubuntu.com-20101129120607-murkfny32efpr1nx
Tags: 3.4.5-0ubuntu1
* New upstream release
* Convert to source format 3.0
  - add debian/format/source
* Update for xulrunner-2.0
  - update debian/control
  - add debian/patches/spidermonkey-2.0.patch for the JSNative changes
  - add debian/patches/series
* Don't call the xulrunner binary to find libmozjs
  - update debian/edbrowse.sh
* Pass -lcrypto and -lreadline to the linker
  - update debian/rules

Show diffs side-by-side

added added

removed removed

Lines of Context:
13
13
/* See eb.h for descriptive comments. */
14
14
 
15
15
 
16
 
const char *version = "3.4.1";
 
16
const char *version = "3.4.5";
17
17
char *userAgents[10], *currentAgent, *currentReferrer;
18
18
const char eol[] = "\r\n";
19
19
char EMPTYSTRING[] = "";
32
32
char *dbarea, *dblogin, *dbpw;  /* to log into the database */
33
33
bool fetchBlobColumns;
34
34
char *proxy_host;
35
 
int proxy_port;
36
35
bool caseInsensitive, searchStringsAll;
37
36
bool undoable;
38
37
bool allowRedirection = true, allowJS = true, sendReferrer = false;
39
38
bool binaryDetect = true;
 
39
bool inputReadLine;
40
40
bool showHiddenFiles, helpMessagesOn;
41
41
uchar dirWrite, endMarks;
42
42
int context = 1;
125
125
    n = cfglen + l;
126
126
    new = allocMem(n);
127
127
    memcpy(new, cfgcopy, subjstart);
128
 
    sprintf(new + subjstart, "%d`%s > x\n", exp, s);
 
128
    sprintf(new + subjstart, "%ld`%s > x\n", exp, s);
129
129
    memcpy(new + subjstart + l, cfgcopy + subjstart, cfglen - subjstart);
130
130
    nzFree(cfgcopy);
131
131
    cfgcopy = new;
168
168
        "adbook", "ipblack", "maildir", "agent",
169
169
        "jar", "nojs", "spamcan",
170
170
        "webtimer", "mailtimer", "certfile", "datasource", "proxy",
171
 
        0
 
171
        "linelength", 0
172
172
    };
173
173
 
174
174
    if(!fileTypeByName(configFile, false))
458
458
 
459
459
        case 6:
460
460
            if(*v == '*')
461
 
                act->inssl = true, ++v;
 
461
                act->inssl = 1, ++v;
462
462
            act->inport = atoi(v);
463
463
            continue;
464
464
 
465
465
        case 7:
 
466
            if(*v == '+')
 
467
                act->outssl = 4, ++v;
 
468
            if(*v == '^')
 
469
                act->outssl = 2, ++v;
466
470
            if(*v == '*')
467
 
                act->outssl = true, ++v;
 
471
                act->outssl = 1, ++v;
468
472
            act->outport = atoi(v);
469
473
            continue;
470
474
 
604
608
 
605
609
        case 28:                /* proxy */
606
610
            proxy_host = v;
607
 
            proxy_port = 80;
608
 
            v = strchr(v, ':');
609
 
            if(v) {
610
 
                *v++ = 0;
611
 
                proxy_port = atoi(v);
612
 
            }
 
611
            continue;
 
612
 
 
613
        case 29:                /* linelength */
 
614
            displayLength = atoi(v);
 
615
            if(displayLength < 80)
 
616
                displayLength = 80;
613
617
            continue;
614
618
 
615
619
        default:
1088
1092
        i_printfExit(MSG_Usage);
1089
1093
    }                           /* options */
1090
1094
 
1091
 
    if(debugLevel >= 4)
1092
 
        curl_easy_setopt(curl_handle, CURLOPT_VERBOSE, 1);
1093
 
 
1094
1095
    if(tcp_init() < 0)
1095
1096
        debugPrint(4, "tcp failure, could not identify this machine");
1096
1097
    else