Search:

Type: Posts; User: flp1969

Page 1 of 20 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    1
    Views
    98

    gSOAP (https://www.genivia.com/dev.html)

    gSOAP
  2. Replies
    4
    Views
    218

    Aren't you forgetting about multibyte charsets?

    Aren't you forgetting about multibyte charsets?
  3. int count_digits( char *s ) { int counter =...

    int count_digits( char *s )
    {
    int counter = 0;

    for (; *s; s++ )
    if ( isdigit( *s ) )
    counter++;

    return counter;
    }
  4. Replies
    4
    Views
    343

    From the wiki article: "All of the integer...

    From the wiki article:

    "All of the integer values are stored in little-endian format (i.e. least-significant byte first)."
  5. Replies
    3
    Views
    829

    IF you are using a multibyte charset (UTF-8, for...

    IF you are using a multibyte charset (UTF-8, for example) you should convert this string to wchar_t string and use wcsrchr() instead of strchr():


    /* test.c */
    #include <stdlib.h>
    #include...
  6. Replies
    6
    Views
    325

    Testing I've got a "segmentation fault" here...

    Testing I've got a "segmentation fault" here...
  7. Replies
    4
    Views
    289

    Maybe you'll find this useful: Simple DirectMedia...

    Maybe you'll find this useful: Simple DirectMedia Layer - Homepage
  8. And to add one more to @Salem's list: - never do...

    And to add one more to @Salem's list:
    - never do this:

    input = realloc(input, size);
    If you do and realloc cannot allocate memory, you'll end up with a "memory leakage".

    []s
    Fred
  9. Be aware that CSV files can use double quotes (")...

    Be aware that CSV files can use double quotes (") to specify strings. For example:

    "String, with comma",10,3.14
    So, tokenizing, using ',' as separator must be done with care.
    There are other...
  10. Replies
    4
    Views
    144

    Another one: printf() should have the format...

    Another one: printf() should have the format string in line 5, as in:

    printf( "%s", argv[1] );
  11. Replies
    4
    Views
    144

    Problems with this code: 1. your buffer (code)...

    Problems with this code:
    1. your buffer (code) has obly 10 chars (as you notice) and 11 bytes are being copied;
    2 '9' (value: 57) is not the same thing as 9;
    3. argv[1] could have less then 10...
  12. Replies
    11
    Views
    427

    fwrite() doesn't work for you?

    fwrite() doesn't work for you?
  13. Replies
    10
    Views
    194

    @Ramsis94, get the GNU C Library manual...

    @Ramsis94, get the GNU C Library manual and take a look at printf() funcion at 12.12.7 (page 277):

    16043

    Notice the "AS-Unsafe" at "Preliminary". This means, printf() isn't safe to use in...
  14. Replies
    10
    Views
    194

    And... avoid to use signal()... it is outdated....

    And... avoid to use signal()... it is outdated.
    Use sigaction().
  15. Read about fscanf().

    Read about fscanf().
  16. Linux ou outro Unix? man 7 signal, veja...

    Linux ou outro Unix?

    man 7 signal, veja SIGPIPE.
  17. Replies
    7
    Views
    330

    Well... Bit inversion is missing: x ^= (1

    Well... Bit inversion is missing:


    x ^= (1 << bit);
  18. Replies
    2
    Views
    151

    In the example, foo is set to 1 and the while...

    In the example, foo is set to 1 and the while loop never ends.
  19. Thread: DataType in C

    by flp1969
    Replies
    8
    Views
    251

    Did you paid attention to the compiler WARNINGS?

    Did you paid attention to the compiler WARNINGS?
  20. Replies
    7
    Views
    330

    Like Zeus_ said... Here's a detailed explanation....

    Like Zeus_ said... Here's a detailed explanation.

    When testing for true or false, any value different from 0 is TRUE. 0 is always FALSE. This expression will isolate bit i of the value from...
  21. Replies
    7
    Views
    353

    Then, it is not possible with your code... result...

    Then, it is not possible with your code... result will have to point to a buffer which requires 2^64 bytes ( 1 EiB ).
  22. You'll need a third loop for a variable square...

    You'll need a third loop for a variable square matrix dimensions...
  23. This way? void m4x4_mult( double *m, double...

    This way?

    void m4x4_mult( double *m, double *n, double *r )
    {
    int i, j;

    for ( i = 0; i < 4; i++ )
    for ( j = 0; j < 4; j++ )
    {
    r[i+4*j] = m[4*j] * n[i] +
  24. Replies
    2
    Views
    193

    Take a look at Gaussian Blur...

    Take a look at Gaussian Blur. Maybe this is what you are looking for.
  25. Replies
    4
    Views
    380

    It is allowed, as an extension, using GCC... But,...

    It is allowed, as an extension, using GCC... But, of couse, it is not advisable:

    #include <stdio.h>

    int main( void )
    {
    void show( void ) { puts( "Hello" ); }

    show();
    }
Results 1 to 25 of 500
Page 1 of 20 1 2 3 4