hello
i have made a small program to find the md5 checksum of a string.i am using xshell to compile the program.
Code:
#include <string.h>
#include <stdio.h>
#include <sys/types.h>
#include <md5.h>
int main(int argc, char * argv) {
MD5_CTX context;
I want to run my C code located in desktop with the header files located in other location. What should be the appropriate gcc command? I have attached the code below.
I'm working on c++, following is my code:
test.h
char[] defaultSurname = "salunke";
void in_dev(const char* name, char* surname = defaultSurname );
test.cpp
#include "test.h"
#include <iostream>
using namespace std;
void in_dev(const char* name, char* surname)
{
cout <<" surname id "<< surname << endl;
}
int main()
{
in_dev("Balaji", "Patil");
return 0;
}
You could try something like the following (just written, untested):#include <stdio.h>
/* seconds between jiffy checks */
static const int timeout = 5;
/* percent cpu use to stay awake */
static const int threshold = 20;
/* sleep when ntimeouts checks are below threshold */
/* This will sleep after 20 minutes below 20% cpu use (240 * 5 sec = 20 min) */
static const int ntimeouts = 240;
s
I am trying to record and playback audio data using pulse audio API in centOS 6.2. But it records and playbacks nothing. I am using a code from pulseaudio. I need help to get it working in my PC. What should I do?
I am getting an error that makes no sense.
Hi everyone,I got error when I run this program. I am using ubuntu 11.10.
This is my program.
Not to be a necromancer or anything but I fixed your examples to work with the current libalpm api/*
* sortpkg.c : Display the locally installed packages sorted by size.
*
*/
#include <stdio.h>
#include <alpm.h>
#include <alpm_list.h>
int pkg_cmp(const void *v1, const void *v2)
{
pmpkg_t *p1 = (pmpkg_t *)v1;
pmpkg_t *p2 = (pmpkg_t *)v2;
unsigned long int s1 = a
Can you help me in finding out why this program is giving segmentation fault?