Ver Mensaje Individual
  #1 (permalink)  
Antiguo 04/04/2016, 07:04
Blast06
 
Fecha de Ingreso: julio-2015
Ubicación: San Juan
Mensajes: 7
Antigüedad: 8 años, 9 meses
Puntos: 0
Pregunta Error undefined reference to Cola y struct

He estado trabajando con este asunto, y bueno, me da este error que ni ideas, este es el código, es una agenda struct con cola:

Código:
#include <stdio.h>
#include <conio.h>
#include <stdlib.h>
#include <string.h>

struct agenda
{
    char nombre[50];
    char telefono[25];
    char mail[50];
};
struct nodo
{
    struct agenda dato;
    struct nodo *proximo;
};

struct nodo *nuevonodo();
int colavacia(struct nodo *);
struct nodo *creacola(struct nodo *, struct agenda);
void mostrar(struct nodo *);

int main()
{


struct nodo *pri=NULL, *ult=NULL;

    struct agenda x;
         printf("Ingrese nombre: ");
    	gets(x.nombre);
    while(strcmpi(x.nombre,"fin"))
    {
        printf("Ingrese telefono: ");
        gets(x.telefono);
        printf("Ingrese mail: ");
        gets(x.mail);
        ult=creacola(ult,x);
        if(pri==NULL) pri=ult; // Si es la 1º pasada pongo en                 pri el valor del primer nodo
        printf("Ingrese nombre: ");
        gets(x.nombre);
    } 
  if(colavacia(pri)==1) { printf("No se ingresaron registros");          
  	getch(); }
    else mostrar(pri);
}

struct nodo *nuevonodo()
{
    struct nodo *p;
    p=(struct nodo *)malloc(sizeof(struct nodo));
    if(p==NULL)
    {
        printf("Memoria RAM Llena");
        getch();
        exit(0);
   }
   return p;
}

El error: