problem with a casted pointer

Discussion in 'C Programming' started by praveen, Jun 29, 2007.

  1. praveen

    praveen Guest

    -------------------------------My dud
    program------------------------------------------
    #include <stdioi.h>
    #include <stddef.h>

    typedef struct dummy{
    int x, y, z;
    }point;

    int main() {
    point a = {1, 2, 3};
    int *p = (int *)(&a + offsetof(point, y);
    int *q = (int *)(&a + offsetof(point, z);
    printf("%d %d", *p, *q);
    return 0;
    }
    -------------------------------------------------------------------------------------------------
    my question is will *p and *q really point to (a.x) and (a.y) ?
    i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    values as output!!!
    praveen, Jun 29, 2007
    #1
    1. Advertising

  2. praveen

    Guest

    On 29 Jun, 12:10, praveen <> wrote:
    > -------------------------------My dud
    > program------------------------------------------
    > #include <stdioi.h>
    > #include <stddef.h>
    >
    > typedef struct dummy{
    > int x, y, z;
    >
    > }point;
    >
    > int main() {
    > point a = {1, 2, 3};
    > int *p = (int *)(&a + offsetof(point, y);


    &a is a pointer to point, so adding offsetof(point,y) will move it on
    "n" points, not "n" bytes. You're now into Undefined Behaviour...

    > int *q = (int *)(&a + offsetof(point, z);


    As above.

    > printf("%d %d", *p, *q);
    > return 0;}
    >
    > -------------------------------------------------------------------------------------------------
    > my question is will *p and *q really point to (a.x) and (a.y) ?


    No.

    > i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    > values as output!!!


    I'm not surprised.

    What are you actually trying to do? Why won't (e.g.) "&a.y" do what
    you need?

    By the way, it's _much_ better to cut and paste your real code, rather
    than type up an approximation. "stdioi.h" doesn't exist and you have
    missing parentheses in your code.
    , Jun 29, 2007
    #2
    1. Advertising

  3. praveen

    Eric Sosman Guest

    praveen wrote:
    > -------------------------------My dud
    > program------------------------------------------
    > #include <stdioi.h>


    I wish, I *wish*, I *REALLY* *WISH* that when people
    post "this is my code" they would actually post their code
    and not some half-baked, typo-ridden approximation! You're
    just introducing extra bugs that divert attention from the
    problem that's actually bothering you; is that wise?

    > #include <stddef.h>
    >
    > typedef struct dummy{
    > int x, y, z;
    > }point;
    >
    > int main() {
    > point a = {1, 2, 3};
    > int *p = (int *)(&a + offsetof(point, y);


    Syntax error. If corrected, probably undefined behavior.

    > int *q = (int *)(&a + offsetof(point, z);


    Syntax error. If corrected, definitely undefined behavior.
    (No, I won't explain why one is "probably" the other "definitely,"
    because I'm angry with you. See above.)

    > printf("%d %d", *p, *q);


    Definitely undefined behavior (twice, or possibly thrice).
    (No, I won't explain the "thrice." See above.)

    > return 0;
    > }
    > -------------------------------------------------------------------------------------------------
    > my question is will *p and *q really point to (a.x) and (a.y) ?


    No, never.

    > i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    > values as output!!!


    You mean, after the required compiler diagnostics about
    the syntax errors and the (probably) non-existent header?
    If you ever expect to become a programmer, you *must* learn
    how to ask questions without distorting the facts!

    <Relenting> You have overlooked a basic fact about pointer
    arithmetic: Adding an integer to a pointer "steps" it in whole
    units of the pointed-to type. Now, ask yourself the question:
    "What is the type of the pointer value `&a'?"

    --
    Eric Sosman
    lid
    Eric Sosman, Jun 29, 2007
    #3
  4. praveen

    Army1987 Guest

    "Eric Sosman" <> ha scritto nel messaggio news:...
    > praveen wrote:
    >> -------------------------------My dud
    >> program------------------------------------------
    >> #include <stdioi.h>

    >
    > I wish, I *wish*, I *REALLY* *WISH* that when people
    > post "this is my code" they would actually post their code
    > and not some half-baked, typo-ridden approximation! You're
    > just introducing extra bugs that divert attention from the
    > problem that's actually bothering you; is that wise?
    >
    >> #include <stddef.h>
    >>
    >> typedef struct dummy{
    >> int x, y, z;
    >> }point;
    >>
    >> int main() {
    >> point a = {1, 2, 3};
    >> int *p = (int *)(&a + offsetof(point, y);

    >
    > Syntax error. If corrected, probably undefined behavior.
    >
    >> int *q = (int *)(&a + offsetof(point, z);

    >
    > Syntax error. If corrected, definitely undefined behavior.
    > (No, I won't explain why one is "probably" the other "definitely,"
    > because I'm angry with you. See above.)


    Because, if sizeof a.x == 1 and there's no padding, then
    offsetof(point, y) is 1, so p points right past the end of the
    fictitious one-element array of point a can be thought to belong
    to. Right?

    >> printf("%d %d", *p, *q);

    >
    > Definitely undefined behavior (twice, or possibly thrice).
    > (No, I won't explain the "thrice." See above.)


    Because it is implementation-defined wheter text files (including
    stdout) need to end with a newline?

    >> return 0;
    >> }

    >
    Army1987, Jun 29, 2007
    #4
  5. praveen

    Eric Sosman Guest

    Army1987 wrote On 06/29/07 09:01,:
    > "Eric Sosman" <> ha scritto nel messaggio news:...
    >
    >>praveen wrote:
    >>
    >>>-------------------------------My dud
    >>>program------------------------------------------
    >>>#include <stdioi.h>

    >>
    >> I wish, I *wish*, I *REALLY* *WISH* that when people
    >>post "this is my code" they would actually post their code
    >>and not some half-baked, typo-ridden approximation! You're
    >>just introducing extra bugs that divert attention from the
    >>problem that's actually bothering you; is that wise?
    >>
    >>
    >>>#include <stddef.h>
    >>>
    >>>typedef struct dummy{
    >>> int x, y, z;
    >>>}point;
    >>>
    >>>int main() {
    >>> point a = {1, 2, 3};
    >>> int *p = (int *)(&a + offsetof(point, y);

    >>
    >> Syntax error. If corrected, probably undefined behavior.
    >>
    >>
    >>> int *q = (int *)(&a + offsetof(point, z);

    >>
    >> Syntax error. If corrected, definitely undefined behavior.
    >>(No, I won't explain why one is "probably" the other "definitely,"
    >>because I'm angry with you. See above.)

    >
    >
    > Because, if sizeof a.x == 1 and there's no padding, then
    > offsetof(point, y) is 1, so p points right past the end of the
    > fictitious one-element array of point a can be thought to belong
    > to. Right?


    Give that man a cigar!

    >>> printf("%d %d", *p, *q);

    >>
    >> Definitely undefined behavior (twice, or possibly thrice).
    >>(No, I won't explain the "thrice." See above.)

    >
    > Because it is implementation-defined wheter text files (including
    > stdout) need to end with a newline?


    Oops! I missed that one. Give *this* man a Bronx cheer!

    --
    Eric Sosman, Jun 29, 2007
    #5
  6. praveen

    Army1987 Guest

    "Eric Sosman" <> ha scritto nel messaggio news:1183128240.330121@news1nwk...
    > Army1987 wrote On 06/29/07 09:01,:
    >> "Eric Sosman" <> ha scritto nel messaggio news:...
    >>
    >>>praveen wrote:
    >>>
    >>>>-------------------------------My dud
    >>>>program------------------------------------------
    >>>>#include <stdioi.h>
    >>>
    >>> I wish, I *wish*, I *REALLY* *WISH* that when people
    >>>post "this is my code" they would actually post their code
    >>>and not some half-baked, typo-ridden approximation! You're
    >>>just introducing extra bugs that divert attention from the
    >>>problem that's actually bothering you; is that wise?
    >>>
    >>>
    >>>>#include <stddef.h>
    >>>>
    >>>>typedef struct dummy{
    >>>> int x, y, z;
    >>>>}point;
    >>>>
    >>>>int main() {
    >>>> point a = {1, 2, 3};
    >>>> int *p = (int *)(&a + offsetof(point, y);
    >>>
    >>> Syntax error. If corrected, probably undefined behavior.
    >>>
    >>>
    >>>> int *q = (int *)(&a + offsetof(point, z);
    >>>
    >>> Syntax error. If corrected, definitely undefined behavior.
    >>>(No, I won't explain why one is "probably" the other "definitely,"
    >>>because I'm angry with you. See above.)

    >>
    >>
    >> Because, if sizeof a.x == 1 and there's no padding, then
    >> offsetof(point, y) is 1, so p points right past the end of the
    >> fictitious one-element array of point a can be thought to belong
    >> to. Right?

    >
    > Give that man a cigar!
    >
    >>>> printf("%d %d", *p, *q);
    >>>
    >>> Definitely undefined behavior (twice, or possibly thrice).
    >>>(No, I won't explain the "thrice." See above.)

    >>
    >> Because it is implementation-defined wheter text files (including
    >> stdout) need to end with a newline?

    >
    > Oops! I missed that one. Give *this* man a Bronx cheer!


    Ah... Then the "thrice" was... now I get it...

    "Possibly" because we don't know that an implementation does not have a <stdioi.h> header which in turn includes <stdio.h>, so we
    don't know for sure that we're calling a variadic function without
    a prototype in scope?
    Army1987, Jun 29, 2007
    #6
  7. praveen

    Eric Sosman Guest

    Army1987 wrote On 06/29/07 11:05,:
    > "Eric Sosman" <> ha scritto nel messaggio news:1183128240.330121@news1nwk...
    >
    >>Army1987 wrote On 06/29/07 09:01,:
    >>
    >>>"Eric Sosman" <> ha scritto nel messaggio news:...
    >>>
    >>>
    >>>>praveen wrote:
    >>>>
    >>>>
    >>>>>-------------------------------My dud
    >>>>>program------------------------------------------
    >>>>>#include <stdioi.h>
    >>>>
    >>>> I wish, I *wish*, I *REALLY* *WISH* that when people
    >>>>post "this is my code" they would actually post their code
    >>>>and not some half-baked, typo-ridden approximation! You're
    >>>>just introducing extra bugs that divert attention from the
    >>>>problem that's actually bothering you; is that wise?
    >>>>
    >>>>
    >>>>
    >>>>>#include <stddef.h>
    >>>>>
    >>>>>typedef struct dummy{
    >>>>> int x, y, z;
    >>>>>}point;
    >>>>>
    >>>>>int main() {
    >>>>> point a = {1, 2, 3};
    >>>>> int *p = (int *)(&a + offsetof(point, y);
    >>>>
    >>>> Syntax error. If corrected, probably undefined behavior.
    >>>>
    >>>>
    >>>>
    >>>>> int *q = (int *)(&a + offsetof(point, z);
    >>>>
    >>>> Syntax error. If corrected, definitely undefined behavior.
    >>>>(No, I won't explain why one is "probably" the other "definitely,"
    >>>>because I'm angry with you. See above.)
    >>>
    >>>
    >>>Because, if sizeof a.x == 1 and there's no padding, then
    >>>offsetof(point, y) is 1, so p points right past the end of the
    >>>fictitious one-element array of point a can be thought to belong
    >>>to. Right?

    >>
    >> Give that man a cigar!
    >>
    >>
    >>>>> printf("%d %d", *p, *q);
    >>>>
    >>>> Definitely undefined behavior (twice, or possibly thrice).
    >>>>(No, I won't explain the "thrice." See above.)
    >>>
    >>>Because it is implementation-defined wheter text files (including
    >>>stdout) need to end with a newline?

    >>
    >> Oops! I missed that one. Give *this* man a Bronx cheer!

    >
    >
    > Ah... Then the "thrice" was... now I get it...
    >
    > "Possibly" because we don't know that an implementation does not have a <stdioi.h> header which in turn includes <stdio.h>, so we
    > don't know for sure that we're calling a variadic function without
    > a prototype in scope?


    Give that man another cigar! (Y'know, you really
    should cut down: Those things are bad for you.)

    --
    Eric Sosman, Jun 29, 2007
    #7
  8. praveen

    Joe Wright Guest

    Eric Sosman wrote:
    > Army1987 wrote On 06/29/07 09:01,:
    >> "Eric Sosman" <> ha scritto nel messaggio news:...
    >>
    >>> praveen wrote:
    >>>
    >>>> -------------------------------My dud
    >>>> program------------------------------------------
    >>>> #include <stdioi.h>
    >>> I wish, I *wish*, I *REALLY* *WISH* that when people
    >>> post "this is my code" they would actually post their code
    >>> and not some half-baked, typo-ridden approximation! You're
    >>> just introducing extra bugs that divert attention from the
    >>> problem that's actually bothering you; is that wise?
    >>>
    >>>
    >>>> #include <stddef.h>
    >>>>
    >>>> typedef struct dummy{
    >>>> int x, y, z;
    >>>> }point;
    >>>>
    >>>> int main() {
    >>>> point a = {1, 2, 3};
    >>>> int *p = (int *)(&a + offsetof(point, y);
    >>> Syntax error. If corrected, probably undefined behavior.
    >>>
    >>>
    >>>> int *q = (int *)(&a + offsetof(point, z);
    >>> Syntax error. If corrected, definitely undefined behavior.
    >>> (No, I won't explain why one is "probably" the other "definitely,"
    >>> because I'm angry with you. See above.)

    >>
    >> Because, if sizeof a.x == 1 and there's no padding, then
    >> offsetof(point, y) is 1, so p points right past the end of the
    >> fictitious one-element array of point a can be thought to belong
    >> to. Right?

    >
    > Give that man a cigar!
    >
    >>>> printf("%d %d", *p, *q);
    >>> Definitely undefined behavior (twice, or possibly thrice).
    >>> (No, I won't explain the "thrice." See above.)

    >> Because it is implementation-defined wheter text files (including
    >> stdout) need to end with a newline?

    >
    > Oops! I missed that one. Give *this* man a Bronx cheer!
    >

    How about..

    int *p = (int*)((char*)&a + offsetof(point,x));

    ...it seems to work but is it correct?

    --
    Joe Wright
    "Everything should be made as simple as possible, but not simpler."
    --- Albert Einstein ---
    Joe Wright, Jun 29, 2007
    #8
  9. praveen

    CBFalconer Guest

    praveen wrote:
    >
    > #include <stdioi.h>
    > #include <stddef.h>
    >
    > typedef struct dummy{
    > int x, y, z;
    > }point;
    >
    > int main() {
    > point a = {1, 2, 3};
    > int *p = (int *)(&a + offsetof(point, y);
    > int *q = (int *)(&a + offsetof(point, z);
    > printf("%d %d", *p, *q);
    > return 0;
    > }
    >
    > my question is will *p and *q really point to (a.x) and (a.y) ?
    > i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    > values as output!!!


    No. *p points to a.y, and *q points to a.z. Remove the casts,
    they are unnecessary and only serve to suppress compiler warnings.
    Use "int main(void)", a better expression. There is no such thing
    as stdioi.h. You want stdio.h.

    --
    <http://www.cs.auckland.ac.nz/~pgut001/pubs/vista_cost.txt>
    <http://www.securityfocus.com/columnists/423>
    <http://www.aaxnet.com/editor/edit043.html>
    cbfalconer at maineline dot net



    --
    Posted via a free Usenet account from http://www.teranews.com
    CBFalconer, Jun 29, 2007
    #9
  10. praveen

    Army1987 Guest

    "Joe Wright" <> ha scritto nel messaggio news:...
    > Eric Sosman wrote:
    >> Army1987 wrote On 06/29/07 09:01,:
    >>> "Eric Sosman" <> ha scritto nel messaggio news:...
    >>>
    >>>> praveen wrote:
    >>>>
    >>>>> -------------------------------My dud
    >>>>> program------------------------------------------
    >>>>> #include <stdioi.h>
    >>>> I wish, I *wish*, I *REALLY* *WISH* that when people
    >>>> post "this is my code" they would actually post their code
    >>>> and not some half-baked, typo-ridden approximation! You're
    >>>> just introducing extra bugs that divert attention from the
    >>>> problem that's actually bothering you; is that wise?
    >>>>
    >>>>
    >>>>> #include <stddef.h>
    >>>>>
    >>>>> typedef struct dummy{
    >>>>> int x, y, z;
    >>>>> }point;
    >>>>>
    >>>>> int main() {
    >>>>> point a = {1, 2, 3};
    >>>>> int *p = (int *)(&a + offsetof(point, y);
    >>>> Syntax error. If corrected, probably undefined behavior.
    >>>>
    >>>>
    >>>>> int *q = (int *)(&a + offsetof(point, z);
    >>>> Syntax error. If corrected, definitely undefined behavior.
    >>>> (No, I won't explain why one is "probably" the other "definitely,"
    >>>> because I'm angry with you. See above.)
    >>>
    >>> Because, if sizeof a.x == 1 and there's no padding, then
    >>> offsetof(point, y) is 1, so p points right past the end of the
    >>> fictitious one-element array of point a can be thought to belong
    >>> to. Right?

    >>
    >> Give that man a cigar!
    >>
    >>>>> printf("%d %d", *p, *q);
    >>>> Definitely undefined behavior (twice, or possibly thrice).
    >>>> (No, I won't explain the "thrice." See above.)
    >>> Because it is implementation-defined wheter text files (including
    >>> stdout) need to end with a newline?

    >>
    >> Oops! I missed that one. Give *this* man a Bronx cheer!
    >>

    > How about..
    >
    > int *p = (int*)((char*)&a + offsetof(point,x));
    >
    > ..it seems to work but is it correct?


    But what's so wrong with good ol' &a.x?
    Army1987, Jun 29, 2007
    #10
  11. praveen

    Army1987 Guest

    "CBFalconer" <> ha scritto nel messaggio news:...
    > praveen wrote:
    >>
    >> #include <stdioi.h>
    >> #include <stddef.h>
    >>
    >> typedef struct dummy{
    >> int x, y, z;
    >> }point;
    >>
    >> int main() {
    >> point a = {1, 2, 3};
    >> int *p = (int *)(&a + offsetof(point, y);
    >> int *q = (int *)(&a + offsetof(point, z);
    >> printf("%d %d", *p, *q);
    >> return 0;
    >> }
    >>
    >> my question is will *p and *q really point to (a.x) and (a.y) ?
    >> i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    >> values as output!!!

    >
    > No. *p points to a.y, and *q points to a.z.

    They don't. And they still wouldn't if we added right parentheses
    before two semicolons.

    What type is &a? What is &a + 1?
    Army1987, Jun 29, 2007
    #11
  12. CBFalconer <> writes:
    > praveen wrote:
    >> #include <stdioi.h>
    >> #include <stddef.h>
    >>
    >> typedef struct dummy{
    >> int x, y, z;
    >> }point;
    >>
    >> int main() {
    >> point a = {1, 2, 3};
    >> int *p = (int *)(&a + offsetof(point, y);
    >> int *q = (int *)(&a + offsetof(point, z);
    >> printf("%d %d", *p, *q);
    >> return 0;
    >> }
    >>
    >> my question is will *p and *q really point to (a.x) and (a.y) ?
    >> i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    >> values as output!!!

    >
    > No. *p points to a.y, and *q points to a.z. Remove the casts,
    > they are unnecessary and only serve to suppress compiler warnings.
    > Use "int main(void)", a better expression. There is no such thing
    > as stdioi.h. You want stdio.h.


    No, *p and *q are of type int, and they don't point to anything.
    (I think you just forgot to drop the '*' characters.)

    But p and q don't point to a.y and a.z anyway; see the other
    responses.

    --
    Keith Thompson (The_Other_Keith) <http://www.ghoti.net/~kst>
    San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
    "We must do something. This is something. Therefore, we must do this."
    -- Antony Jay and Jonathan Lynn, "Yes Minister"
    Keith Thompson, Jun 29, 2007
    #12
  13. praveen

    helloguys Guest

    On 6 29 , 7 10 , praveen <> wrote:
    > -------------------------------My dud
    > program------------------------------------------
    > #include <stdioi.h>
    > #include <stddef.h>
    >
    > typedef struct dummy{
    > int x, y, z;
    >
    > }point;
    >
    > int main() {
    > point a = {1, 2, 3};
    > int *p = (int *)(&a + offsetof(point, y);
    > int *q = (int *)(&a + offsetof(point, z);
    > printf("%d %d", *p, *q);
    > return 0;}
    >
    > -------------------------------------------------------------------------------------------------
    > my question is will *p and *q really point to (a.x) and (a.y) ?
    > i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    > values as output!!!





    i think you made a misunderstand of *a* and *&a*;
    *a* is the begin address of the struct ,
    and &a is a pointer who point to the address a, if sizeof(a)=12 (no
    padding)
    then &a +2 =a+2*12 and is beyond the struct a, so you got the garbage
    output.
    helloguys, Jul 2, 2007
    #13
  14. praveen

    praveen Guest

    On Jun 29, 4:32 pm, wrote:
    > On 29 Jun, 12:10, praveen <> wrote:
    >
    > > -------------------------------My dud
    > > program------------------------------------------
    > > #include <stdioi.h>
    > > #include <stddef.h>

    >
    > > typedef struct dummy{
    > > int x, y, z;

    >
    > > }point;

    >
    > > int main() {
    > > point a = {1, 2, 3};
    > > int *p = (int *)(&a + offsetof(point, y);

    >
    > &a is a pointer to point, so adding offsetof(point,y) will move it on
    > "n" points, not "n" bytes. You're now into Undefined Behaviour...
    >
    > > int *q = (int *)(&a + offsetof(point, z);

    >
    > As above.
    >
    > > printf("%d %d", *p, *q);
    > > return 0;}

    >
    > > ---------------------------------------------------------------------------­----------------------
    > > my question is will *p and *q really point to (a.x) and (a.y) ?

    >
    > No.
    >
    > > i ran this program on DevC++ 4.9.9.2 and i'm getting some garbage
    > > values as output!!!

    >
    > I'm not surprised.
    >
    > What are you actually trying to do? Why won't (e.g.) "&a.y" do what
    > you need?
    >
    > By the way, it's _much_ better to cut and paste your real code, rather
    > than type up an approximation. "stdioi.h" doesn't exist and you have
    > missing parentheses in your code.

    actually i used <stdio.h> in my code but <stdioi.h> is a typo just
    replace it with stdio.h
    praveen, Jul 19, 2007
    #14
  15. praveen

    Flash Gordon Guest

    praveen wrote, On 19/07/07 07:57:
    > On Jun 29, 4:32 pm, wrote:


    <snip>

    >> By the way, it's _much_ better to cut and paste your real code, rather
    >> than type up an approximation. "stdioi.h" doesn't exist and you have
    >> missing parentheses in your code.

    > actually i used <stdio.h> in my code but <stdioi.h> is a typo just
    > replace it with stdio.h


    That is precisely why Mark said that you should copy and paste. It was
    obvious that that error was a typo, but how many other errors in the
    code you posted were typos rather than errors in your real code?

    NEVER retype your code, ALWAYS copy and paste it in to your posts. That
    way people will be able to see your code errors rather than your typing
    errors.
    --
    Flash Gordon
    Flash Gordon, Jul 19, 2007
    #15
  16. On Fri, 29 Jun 2007 12:36:20 -0400, Joe Wright
    <> wrote:
    <snip>
    > >>>> typedef struct dummy{
    > >>>> int x, y, z;
    > >>>> }point;
    > >>>> point a = {1, 2, 3};

    <snip>
    > How about..
    >
    > int *p = (int*)((char*)&a + offsetof(point,x));
    >
    > ..it seems to work but is it correct?


    Since no one else has actually confirmed this yet ...

    yes. At least technically, i.e. it portably computes the correct
    address, with the correct type.

    It is ugly; and fragile, hence hard to maintain; and thus not a good
    design choice unless really needed. Using a.x, and &a.x, etc., is as
    already noted preferable whenever (reasonably) possible.

    Aside: for x in particular, since it is the first member in the
    example, its offset is (always) 0 and just
    int * p = (int*) & a;
    is fine. But I took the question to be, as it usually is, about an
    arbitrary member, not (necessarily) the first.

    - formerly david.thompson1 || achar(64) || worldnet.att.net
    David Thompson, Jul 22, 2007
    #16
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Pat
    Replies:
    1
    Views:
    258
    Victor Bazarov
    Feb 22, 2007
  2. kkirtac

    Problem on using a casted void pointer

    kkirtac, Sep 23, 2007, in forum: C Programming
    Replies:
    10
    Views:
    636
    kkirtac
    Sep 24, 2007
  3. Ravi
    Replies:
    11
    Views:
    1,352
  4. Raj Pashwar

    problem with a casted pointer

    Raj Pashwar, Oct 8, 2011, in forum: C Programming
    Replies:
    4
    Views:
    319
    Morris Keesan
    Oct 10, 2011
  5. Replies:
    2
    Views:
    76
    Barry Schwarz
    Feb 14, 2014
Loading...

Share This Page