voici mon code

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include <stdio.h>
#include <stdlib.h>
#include<string.h>
typedef struct { char *nomvil;
                 long int nbrvil;}ville;
int main(int argc, char *argv[])
{ char *nom;
  long int population;
  puts("donnez le nom de la ville\n");
  gets(nom);
  ville creeerville( char *nom, long int population)
  { ville c; int k;
  k=strln(nom);
  *(c.nomvil)=(char*)malloc(k*sizeof(char));
        strcpy( (c.nomvil),nom);
        c.nbrvil=population; 
        return c;}
 
  system("PAUSE");	
  return 0;
}
mais a chaque fois il m'affiche ce message d'erreur
[Warning] assignment makes integer from pointer without a cast
je suis débutant et je sais ou est le problème aidez moi s.v.p et merci d'avance