Page 2 of 2 FirstFirst 12
Results 11 to 14 of 14

Thread: Can't run libcod

  1. #11
    Assadministrator kung foo man's Avatar
    Join Date
    Jun 2012
    Location
    trailerpark
    Posts
    2,011
    Thanks
    2,102
    Thanked 1,084 Times in 753 Posts
    When the history buffer in normal Terminal is not big enough, just install GNU/Screen "screen":
    Code:
    apt-get install screen
    With default history size it's possible to scroll all the way up (here at least ^^).

    Hm, then the error output of the subprocesses isn't redirected. This should work:

    Code:
    ./doit.sh base > test.txt 2>&1
    Code:
    ./doit.sh base 2>&1 | tee > test.txt
    timescale 0.01

  2. The Following User Says Thank You to kung foo man For This Useful Post:

    PureTryOut (22nd April 2014)

  3. #12
    ... connecting
    Join Date
    Jan 2014
    Posts
    8
    Thanks
    5
    Thanked 0 Times in 0 Posts
    Like I said, it's not that the history is too short, it just clears the screen (console command "clear") somehow.
    Doesn't matter though now I know how to log screen sessions.

    Anyways this seemed to work!
    Error output:
    Code:
    ##### COMPILE GSC_ASTAR.CPP #####
    ##### COMPILE GSC_MYSQL.CPP #####
    gsc_mysql.cpp: In function ‘void gsc_mysql_free_result()’:
    gsc_mysql.cpp:529:15: warning: NULL used in arithmetic [-Wpointer-arith]
      if(result == NULL)
                   ^
    gsc_mysql.cpp: In function ‘int gsc_mysql_test_0()’:
    gsc_mysql.cpp:880:55: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘my_ulonglong {aka long long unsigned int}’ [-Wformat=]
      printf("affected rows: %d\n", mysql_affected_rows(my));
                                                           ^
    gsc_mysql.cpp:892:54: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘my_ulonglong {aka long long unsigned int}’ [-Wformat=]
      printf("query-num rows: %d\n", mysql_num_rows(query));
                                                          ^
    gsc_mysql.cpp: In function ‘int gsc_mysql_test_1()’:
    gsc_mysql.cpp:972:47: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long unsigned int’ [-Wformat=]
       printf("stmt->stmt_id = %d\n", stmt->stmt_id);
                                                   ^
    gsc_mysql.cpp:973:59: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long unsigned int’ [-Wformat=]
       printf("stmt->prefetch_rows = %d\n", stmt->prefetch_rows);
                                                               ^
    gsc_mysql.cpp:993:47: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long unsigned int’ [-Wformat=]
       printf("stmt->stmt_id = %d\n", stmt->stmt_id);
                                                   ^
    gsc_mysql.cpp:994:59: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long unsigned int’ [-Wformat=]
       printf("stmt->prefetch_rows = %d\n", stmt->prefetch_rows); // i dont know
                                                               ^
    gsc_mysql.cpp:1146:55: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘my_ulonglong {aka long long unsigned int}’ [-Wformat=]
      printf("affected rows: %d\n", mysql_affected_rows(my));
                                                           ^
    gsc_mysql.cpp:1158:54: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘my_ulonglong {aka long long unsigned int}’ [-Wformat=]
      printf("query-num rows: %d\n", mysql_num_rows(query));
                                                          ^
    ##### COMPILE SERVER.CPP #####
    cc1: warning: command line option ‘-std=gnu++11’ is valid for C++/ObjC++ but not for C [enabled by default]
    server.c: In function ‘mythread’:
    server.c:244:6: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘void **’ [-Wformat=]
          sscanf(arg_from, "%x", &from); // prepare from-pointer
          ^
    server.c:311:7: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘float **’ [-Wformat=]
           sscanf(address, "%x", &ptr_float);
           ^
    server.c:328:7: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘int **’ [-Wformat=]
           sscanf(address, "%x", &ptr);
           ^
    server.c:345:7: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘unsigned char **’ [-Wformat=]
           sscanf(address, "%x", &ptr);
           ^
    server.c:387:6: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘char **’ [-Wformat=]
          sscanf(arg_from, "%x", &from);
          ^
    server.c:388:6: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘char **’ [-Wformat=]
          sscanf(arg_to, "%x", &to);
          ^
    server.c:433:6: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘unsigned int **’ [-Wformat=]
          sscanf(arg_address, "%x", &address);
          ^
    server.c:460:6: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘void **’ [-Wformat=]
          sscanf(arg_addr, "%x", &addr);
          ^
    server.c: In function ‘cdecl_injected_shell’:
    server.c:718:5: warning: format ‘%x’ expects argument of type ‘unsigned int *’, but argument 3 has type ‘unsigned int **’ [-Wformat=]
         sscanf(buffer, "%x", &address);
         ^
    ##### COMPILE GSC_MEMORY.CPP #####
    ##### COMPILE cracking.CPP #####
    ##### COMPILE GSC_MATH.CPP #####
    Although it is the same output as in my first post, I hope this helps.

  4. #13
    Assadministrator kung foo man's Avatar
    Join Date
    Jun 2012
    Location
    trailerpark
    Posts
    2,011
    Thanks
    2,102
    Thanked 1,084 Times in 753 Posts
    There is no error at all, just warnings based on gcc nitpicking. Compilation/linking should work without problems.

    If you dare, you can add warning-ignore-flags for these in doit.sh and tell us how to disable them on never gcc versions.
    timescale 0.01

  5. #14
    ... connecting
    Join Date
    Jan 2014
    Posts
    8
    Thanks
    5
    Thanked 0 Times in 0 Posts
    Ooh well it's fine then, thanks for your help!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •