Search:

Type: Posts; User: siubo

Search: Search took 0.01 seconds.

  1. Thread: unknown fault

    by siubo
    Replies
    6
    Views
    1,583

    There is no 'Seg fault.' printed out. What does...

    There is no 'Seg fault.' printed out.
    What does it indicate?
    How to test the return value of malloc?
  2. Replies
    5
    Views
    1,245

    I think I have declared it. As I mentioned, there...

    I think I have declared it. As I mentioned, there is a similar function called 'extract_ip_patterns' which is used in the same program.
    But, there is no problem on using this function. And, I have...
  3. Thread: unknown fault

    by siubo
    Replies
    6
    Views
    1,583

    I'm sorry that I don't understand your reply

    I'm sorry that I don't understand your reply
  4. Replies
    5
    Views
    1,245

    I'm sorry that I can't understand. Can you...

    I'm sorry that I can't understand. Can you explain it in more details?
  5. Thread: malloc

    by siubo
    Replies
    10
    Views
    1,785

    I change it because I have a segmentation fault...

    I change it because I have a segmentation fault when I run my program. I have posted this message before.
    Somebody said that I did sth. wrong with the memory. So, I try to change it to fix the...
  6. Replies
    5
    Views
    1,245

    implicit declaration

    I have defined two functions:
    extract_ip_patterns and extract_op_patterns.
    They are almost the same and used in the same main program. But there is a warning message about extract_op_patterns:
    ...
  7. Thread: malloc

    by siubo
    Replies
    10
    Views
    1,785

    When I follow the FAQ to change #define...

    When I follow the FAQ to change
    #define Malloc(type,n) (type *)malloc((n)*sizeof(type))
    to
    #define Malloc(ptr,n) malloc(n*sizeof *ptr),
    however, error messages are come out:
    cannot convert...
  8. Thread: malloc

    by siubo
    Replies
    10
    Views
    1,785

    I'm sorry that I haven't read the FAQ before...

    I'm sorry that I haven't read the FAQ before posting question. Thank you for reminding me.

    What is n?
  9. Thread: unknown fault

    by siubo
    Replies
    6
    Views
    1,583

    unknown fault with code

    This is part of my code where I guess that the problem is here:
    **************************************************


    void read_problem(char *filename)
    {
    int elements, max_index, i, j, index,...
  10. Thread: unknown fault

    by siubo
    Replies
    6
    Views
    1,583

    unknown fault

    I'm running my C program on Linux. An error message is come out:
    Segmentation fault

    Can anyone help me to suggest any possible reasons which cause the error>
  11. Thread: malloc

    by siubo
    Replies
    10
    Views
    1,785

    Thank you! How abt this?

    What does it mean?

    #define Malloc(type,n) (type *)malloc((n)*sizeof(type))
  12. Thread: malloc

    by siubo
    Replies
    10
    Views
    1,785

    malloc

    What is the use of malloc()?
    How to use it? And, what is the return of malloc()?
  13. Thread: gnuplot

    by siubo
    Replies
    3
    Views
    1,398

    Thank you

    Thank you all to reply me
  14. Thread: gnuplot

    by siubo
    Replies
    3
    Views
    1,398

    gnuplot

    Dear all,

    In C/C++, is there a built-in function called gnuplot in Linux OS? It is used to create a 2-D plot.
    Also, is there Matlab in Linux OS?
  15. Replies
    1
    Views
    1,301

    undefined reference

    This is my C code:
    int main(int argc, char **argv)
    {
    vec_t **x;
    PATTERN *pat;
    unsigned long num_patfiles, total_num_pats;
    pat = (PATTERN *) get_pattern("faem0.test.pds",...
  16. Replies
    1
    Views
    2,176

    (pattern *) pat & pattern * pat

    what is the difference between 1 & 2?

    1. pat = (PATTERN *)
    vector(1,(int)*num_patfiles,sizeof(PATTERN));

    2. pat = PATTERN * vector(1,(int)*num_patfiles,sizeof(PATTERN));
  17. Thread: Vector_type?

    by siubo
    Replies
    2
    Views
    1,127

    Thanks

    Thank you for your reply
  18. Thread: Vector_type?

    by siubo
    Replies
    2
    Views
    1,127

    Vector_type?

    I have met the following code:

    #ifndef vec_t
    typedef VECTOR_TYPE vec_t;
    #endif

    Is VECTOR_TYPE a program default word or uer defined word?
  19. Replies
    4
    Views
    1,455

    Thank you

    Thank you for your reply
  20. Replies
    4
    Views
    1,455

    Thank you for your reply. One more question......

    Can you explain more about what means of 'If you don't specify the object file with -o, it defaults to a.out.'?

    Also, if i have a file to pass in the program, how can I do this?
  21. Replies
    4
    Views
    1,455

    How to compile C program in Linux?

    I'm a beginner to use Linux OS. I don't know how to compile and run a C program in Linux. Can anyone help one?
  22. Replies
    1
    Views
    829

    Is it a build-in function?

    Dear all,

    This is my first time to post message here. I'm glad to see you all here.

    I have met a function called Malloc. There is a line as below:
    #define Malloc(type,n) (type...
Results 1 to 22 of 22