Why do you i get this problem?? :(

This is a discussion on Why do you i get this problem?? :( within the C++ Programming forums, part of the General Programming Boards category; Hello, i posted few days back about T9 dictionary problem. I have solved the program with part of C functions ...

  1. #1
    Registered User
    Join Date
    Jan 2008
    Posts
    225

    Why do you i get this problem?? :(

    Hello,
    i posted few days back about T9 dictionary problem. I have solved the program with part of C functions and part of C++ functions because in our college still C++ file part is not taught to us, so i made it partly in C and partly in C++. Anyways my problem is the whole program runs perfectly but at the end of the execution i get statement....


    NULL POINTER ASSIGNMENT

    this is my only problem..i don't know why is this problem coming please help me

  2. #2
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    You get it because you are trying to set something via a NULL pointer. A trivial example would be:
    Code:
    int *ptr;
    ptr = NULL;
    ...
    *ptr = 7;   // Pointer is NULL, so a "NULL POINTER ASSIGNMENT".
    Of course, the pointer where this fails could be part of a data structure, or otherwise "hidden".

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  3. #3
    Registered User
    Join Date
    Jan 2008
    Posts
    225
    Ok yo matsp got it!! only 1 little silly mistake was there
    Thanks mats

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need help understanding a problem
    By dnguyen1022 in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2009, 05:21 PM
  2. Memory problem with Borland C 3.1
    By AZ1699 in forum C Programming
    Replies: 16
    Last Post: 11-16-2007, 11:22 AM
  3. Someone having same problem with Code Block?
    By ofayto in forum C++ Programming
    Replies: 1
    Last Post: 07-12-2007, 09:38 AM
  4. A question related to strcmp
    By meili100 in forum C++ Programming
    Replies: 6
    Last Post: 07-07-2007, 03:51 PM
  5. WS_POPUP, continuation of old problem
    By blurrymadness in forum Windows Programming
    Replies: 1
    Last Post: 04-20-2007, 07:54 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21