Questions tagged as 'ponteiro'

1
answer

Segmentation float when starting the function for the second time

I created a program in c ++ to manipulate arrays, and split the source code into 2 files, one with functions and the other with implementation, all functions work correctly, however when starting any function for the second time, regardless of w...
asked by 18.10.2017 / 19:45
1
answer

Files For Structs / C Pointers

I have this little program and I am able to save, and load from the file to struct (not perfectly). The error is as follows: after loading the file to struct, if in the function load by printf it will correctly print all the files of the stru...
asked by 04.10.2017 / 05:20
1
answer

Chained list returning empty out of function

I'm trying to read data from a .obj file and insert it into a linked list, I have a function to read and inside it I call the insert function. When I call the function to print the list inside the read function after having entered all th...
asked by 15.09.2017 / 02:27
1
answer

Chained list prints in addition to what is inserted

I have this function verticeobj* loadverticeObj(char *fname,verticeobj *vo){ FILE *fp; int read; float x, y, z; char ch; fp=fopen(fname,"r"); if (!fp) { printf("can't open file %s\n", fname); exit(1...
asked by 15.09.2017 / 19:10
1
answer

Warning on battery pointers

I'm trying to do a simple stack implementation, however the message appears:    warning: initialization from incompatible pointer type   -Wincompatible-pointer-types This warning appears on both line 20 and line 29. These pointers a...
asked by 15.09.2017 / 19:01
1
answer

Pointer pointer passing by reference

I'm doing a program where I need to dynamically allocate 2 arrays, so I thought of doing this allocation within a function. I tried to do this, but it is giving "Targeting failed". Could someone help me? void CriaMatriz(int ***matriz, int linh...
asked by 19.08.2017 / 03:53
1
answer

Print item from a queue by removing each item from it

I'm doing a program that receives a string with comma-separated words that separates those words and lines them (so far I've been able to do it quietly), then the program has to remove and print the items, but I can not develop the de-working fu...
asked by 10.07.2017 / 05:32
1
answer

Error TESTE500K.c :(. text + 0x8f): undefined reference to 'INSERE'

Galera, I'm trying to create a list but are giving these errors TESTE500K.c :(.text + 0x8f): undefined reference to 'INSERE' TESTE500K.c: (. text + 0xa5): undefined reference to 'PRINT' [Error] ld returned 1 exit status I would have to...
asked by 14.06.2017 / 01:11
0
answers

'fscanf' changing pointer to struct in C

Good evening. I was writing a program to read strings from a text file, and place these in a simply linked list if its length was equal to 5. The problem is that the program started not working the way I did I expected, and after a few tes...
asked by 29.04.2017 / 03:55
1
answer

Run-time error in C [closed]

Well, it's compiling everything ok, however, when I'm going to print the elements of the entire array tab [8] [8], which is a member of the lady structure, the compiler is somehow assigning numbers to this array, the which I do not know where th...
asked by 29.01.2017 / 08:38