C Programming Tutorials

C Programming Tutorials And Articles
  Title / Author Reverse Sort Order Replies
Views
Abstract Introduction The interview text References Abstract This is an interview with Dmitriy Vyukov - the author of Relacy Race Detector (RRD) tool intended for verifying parallel applications. In this article you will learn about the history of creating RRD, its basic abilities and...
0
1,868
Abstract Introduction size_t type ptrdiff_t type Portability of size_t and ptrdiff_t Safety of ptrdiff_t and size_t types in address arithmetic Performance of code using ptrdiff_t and size_t Code refactoring with the purpose of moving to ptrdiff_t and size_t References
4
4,007
I've arrived at the source code of a widely know instant messenger Miranda IM. Together with various plugins, this is a rather large project whose size is about 950 thousand code lines in C and C++. And like any other considerable project with a long development history, it has rather many errors...
0
3,798
This is the third article where I will tell you about a couple of new programming methods that can help you make your code simpler and safer. You may read the previous two posts here and here . This time we will take samples from the Qt project. Introduction It was not accidentally that I...
2
3,159
This time we checked Apache HTTP Server with PVS-Studio. As we had expected, we found errors there. The errors are few. We expected this either. Other developers come across this situation too while testing PVS-Studio on their projects. Unfortunately, the first conclusion you would like to draw...
0
2,240
This is the fourth post in which I want to share with you some useful observations on error patterns and the ways of fighting them. This time I will touch upon the subject of handling rare and emergency conditions in programs. While examining a number of applications, I came to a conclusion that...
0
1,893
This time I want to speak on the 'printf' function. Everybody has heard of software vulnerabilities and that functions like 'printf' are outlaw. But it's one thing to know that you'd better not use these functions, and quite the other to understand why. In this article, I will describe two classic...
4
5,553
Pointer and reference maybe same at assembly level. Try an experiment : # include<stdio.h> int main() { int i =90; int *pointer; int &reference = i; // Line 6
4
3,765
A simple code of Http-Web-Server in C done by a beginner level programmer. Please suggest if you liked it and lets make it better !! Hows that!!! The Code #include<stdio.h> #include<string.h> #include<arpa/inet.h> #include<netdb.h> #include<sys/types.h> #include<sys/socket.h>
31
8,458
What is a socket? See there are many types of sockets hardware sockets “like electrical sockets” etc. and software “programming sockets” like what i'm going to talk about from now onwards. See , a socket can be thought like any standard way to perform network communication through our system...
11
5,168
Stack is a LIFO abstract type of data structure. The stack is mainly associated with 2 types of functions Push() and Pop(). Push() adds an item on the top of the stack and Pop() removes an item from the top of the stack. Implementation of Stack stack.c #include<stdio.h> #include<string.h>...
1
9,224
Stack is a Last in First out(LIFO) abstract data structure...Stack is used as the main data structure for processing and data management on most of the OS architectures...like intel x86 etc etc.. Stack based Overflows It happens when to much data is passed on the call stack and results in...
4
3,783
Note : The following source will only work with non-chunked encoding servers...The servers which have enabled the encoding set to chunked will not properly work with this source... And I assume basic knowledge of SOCKETS UNIX API and C language as prerequisites... Source #include<stdio.h>...
5
7,228
Format strings are the strings mainly associated with printf's set of instructions (like printf,fprintf etc..) which basically stands for print format.... These functions accept several arguments and put them on the stack..and as a format specifier is noted in the string the function pops the data...
1
2,893
Continuation of Shell-coding basics..I suggest a glance over it before you start reading this.. Testing We'll be using a simple C program to accomplish our task. test.c // #include<stdio.h> we will not be needing this as we are not using any functions from the C library...Just basic...
1
2,965
EIP ( Extended Instruction Pointer ) is a register that points to the next instruction...It simply points to the address in which that instruction is placed...So if we overwrite this we can change the direction flow of the program and make it do what we want.... In other words if we overwrite...
2
8,327
Processes are the primitive units for alocation of system resources...Each process have their own address space and usually one thread of control. The process which makes another process is called the parent and the process which it makes is called a child process..As we know every process have its...
14
8,653
Integers is a fundamental data type in a C program, They are used to represent a finite subset of mathematical integers, C Provides us with a suite of functions, and quite a lot of modifiers for manipulating these integers , but if these functions and modifiers are not used properly and carefully...
3
4,982
Today while solving a problem, I had to convert integers to string in C to use its indexing capabilities. One simple solution was to use sprintf, which can be done in 2-3 lines, but i was temped to solve this problem without any string manipulation functions. The Code // Change a positive...
4
5,138
In this tutorial, we'll be looking at the code structure of the 'echo' utility and will try to understand how it works, for those who are unfamilliar with the 'echo' utility, its one of the most basic and most useful utilities in a shell it prints out its arguments on the standard output, if you...
0
2,295