I am creating an executable with this: gcc elliptical.o -Llibs -lhfcal -o elliptical In my libs sub folder there are: libhfcal.a libhfcal.so files. My purpos
I have simple code that reads a .jpg file But my read returns 0 and errno is 0. I just prefer of use read with read syscall. #include <stdio.h> #include &
I have intel system with Ethernet controller: Intel Corporation 82579LM Gigabit Network Connection (Lewisville) (rev 04). I have downloaded the datasheet like d
I have a strange problem with gcc and constants and .rodata Let's assume: typedef const struct { const char *a; } data_t; typedef const struct { const dat
I'm pretty new to C and I can't figure out why I'm getting a segmentation fault from this code: void delete_list(LIST *list) { NODE* n = list->head; whil
I have been doing a school project about digital watermark based on DCT using LabWindows CVI 2012. I divide an image with the size of 512 * 512 into many 8 * 8
I have been doing a school project about digital watermark based on DCT using LabWindows CVI 2012. I divide an image with the size of 512 * 512 into many 8 * 8
I have two functions. One that returns the part of the string for me. Don't ask me why I'm doing it inside a function because I want to run this inside a thread
BACKGROUND: I read several articles about performance benchmarks between LuaJIT and C-language. There were different conclusions, so I tried to compare the spee
I just created a DLL in C with Python in it. When I export my function with python functions in it, I can't call it in my Python code But when I export a classi
I have a gtk scale with range, and my goal is to capture when the user releases the click from the scale. (value-changed is called even when the slider is still
Below I have a struct with multiple dynamically allocated char arrays. It compiles, Valgrind indicates no issues and it functions as anticipated. Earlier, someo
Suppose I have N items and a binary number that represents inclusion of these items in a result: N = 4 # items 1 and 3 will be included in the result vector =
I have the following C code: #include <stdio.h> #include <stdlib.h> typedef struct num { int a; struct num *c; } num; void init_struct(num *n)
Our internal program is written in C and makes extensive use of snprintf() for many pieces, and I noticed that during debugging with perf record/report, it's sp
I have a struct typedef struct hash_entry_{ char *string; void *data; struct hash_entry *next; }hash_entry, *p_entry; I am referencing p_entry later i
Hi all i am converting my C code to MIPS but problem is here i couldn't make correct logic for this for (int i=0;i<count;i++) { h[a[i]]++; } as
I would like to run ansi C unit tests in VS by mean of Test Explorer (not only with Console). I saw that it's possible for C++ projects (https://docs.microsoft.
I have been trying to append raw bytes to an existing zlib stream using the deflatePrime function provided by the zlib library. However, i cannot understand wha
Let's say I have this struct typedef struct { int AM; char* name, surname; }Item; and I want to define a constant NULLitem with AM = -1 and NULL name/