Changeset f6190dd for installer/c


Ignore:
Timestamp:
Apr 3, 2013 1:55:02 AM (7 years ago)
Author:
str4d <str4d@…>
Branches:
master
Children:
7f471910
Parents:
51f072c
Message:

Get a simple I2P.exe working

File:
1 edited

Legend:

Unmodified
Added
Removed
  • installer/c/i2pExe/i2p.c

    r51f072c rf6190dd  
    2828main(int argc, char** argv) {
    2929
    30         int read_options_size;
    31         char** read_options;
     30        //int read_options_size;
     31        //char** read_options;
    3232        int ret = 0;
    33         int current_argc = 0;
    34         int new_argc;
    35         char** new_argv;
    36         int i;
     33        //int current_argc = 0;
     34        //int new_argc;
     35        //char** new_argv;
     36        //int i;
    3737        char currentDirectory[MAX_PATH+1];
    3838
     
    4242        // Read in options from disk (launch.properties)
    4343        // or the default ones (if no launch.properties existed)
    44         readOptions(&read_options, &read_options_size);
     44        //readOptions(&read_options, &read_options_size);
    4545
    4646        // Construct a new argc & argv to pass to launchJVM
    47         new_argc = read_options_size + argc;
    48         new_argv = (char**)MemAlloc(sizeof(char*) * (new_argc+1));
     47        //new_argc = read_options_size + argc;
     48        //new_argv = (char**)MemAlloc(sizeof(char*) * (new_argc+1));
    4949
    5050        // copy process name
    51         new_argv[0] = argv[0];
     51        //new_argv[0] = argv[0];
    5252        // copy arguments from properties file
    53         for(i = 1; i <= read_options_size; i++)
    54                 new_argv[i] = read_options[i-1];
     53        //for(i = 1; i <= read_options_size; i++)
     54        //      new_argv[i] = read_options[i-1];
    5555        // copy argv arguments as arguments after the properties file
    5656        // (generally used as arguments for I2P)
    57         for(current_argc = 1; current_argc < argc; current_argc++)
    58                 new_argv[i++] = argv[current_argc];
    59 
    60         new_argv[i] = NULL;
     57        //for(current_argc = 1; current_argc < argc; current_argc++)
     58        //      new_argv[i++] = argv[current_argc];
     59
     60        //new_argv[i] = NULL;
    6161
    6262        // options are no longer necessary -- free them up.
    63         if(read_options != 0)
    64                 free(read_options);
    65 
    66     ret = launchJVM(new_argc, new_argv);
    67         free(new_argv);
     63        //if(read_options != 0)
     64        //      free(read_options);
     65
     66    //ret = launchJVM(new_argc, new_argv);
     67        //free(new_argv);
     68        ret = launchJVM(argc, argv);
    6869        switch(ret) {
    6970        case ERROR_COULDNT_FIND_JVM:
Note: See TracChangeset for help on using the changeset viewer.