Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1042807
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T15:34:01+00:00 2026-05-16T15:34:01+00:00

I am new to linux c programming and i have a simple program just

  • 0

I am new to linux c programming and i have a simple program just for learning and when i compile it it gives me error “dereferencing pointer to incomplete type” here is my code

struct Node
{
    struct Node* left;
    struct Node* middle;
    struct Node* right;
    int nodeData;
    int nodeLevel;
    char isVisted;
};
struct ListNode
{
    struct Node* data;
    struct ListNode* next;
};

struct List
{
    struct NodeList* head;
    struct NodeList* tail;
    int count;
};

typedef struct ListNode ListNode;
typedef struct Node Node;
typedef struct List List;

ListNode* InitListNode(Node* data)
{
    ListNode* listNode=(ListNode*)calloc(1,sizeof(ListNode));
    listNode->data=data;
    listNode->next=NULL;
    return listNode;
}

List* InitList()
{
    List* list=(List*)calloc(1,sizeof(List));
    list->count=0;
    list->head=list->tail=NULL;
}

void EnQue(Node* data,List* que)
{
    if(que->count==0)
    {
        que->tail=que->head=InitListNode(data);
        que->count++;
    }
    else
    {
        que->tail->next=InitListNode(data); //here error is problem comes 
        que->tail=que->tail->next;//here error is problem comes
        que->count++;
    }
}

please help..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T15:34:02+00:00Added an answer on May 16, 2026 at 3:34 pm

    head and tail in struct List are of type NodeList. Should be ListNode?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

see i have make one program which create one new file just using fopen()
I am new to C programming. I have two Linux machine. I want to
I'm very new to Linux and programming on Linux. I'm trying to install OpenAL
I'm new to programming with linux and I was trying to understand how fork()
I'm pretty new to programming for Linux environments, so I don't exactly know what
i am new in programming under linux and trying to get working this code:
I'm new to Linux, Python and the Anjuta IDE. I have created a new
I am a new comer to Linux Kernel Module programming. From the material that
I'm quite new to Android programming but familiar with C/C++ and Linux enough to
I am new to Linux programming and am attempting to use the BFD library.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.