comp.lang.c
  Home FAQ Contact Sign in
comp.lang.c only
 
Advanced search
February 2008
motuwethfrsasuw
    123 5
45678910 6
11121314151617 7
18192021222324 8
2526272829   9
2008
 Jan   Feb   Mar   Apr 
 May   Jun   Jul   Aug 
 Sep   Oct   Nov   Dec 
2008 2007 2006  
total
comp.lang.c Profile…
RELATED GROUPS

POPULAR GROUPS

more...

 Up
  Best Prometric (like Microsoft, Sun Microsystems, Dell, HP) Test center In Bangalore         


Author: Prometric Test center
Date: Feb 22, 2008 23:44

Best Prometric (like Microsoft, Sun Microsystems, Dell, HP) Test
center In Bangalore

Hi Guys,

Greetings from Everonn!!!!

Are you looking for the good Prometric (like Microsoft, Sun
Microsystems, Dell, and HP) Test center, where you can take test
whenever you want...?

Then you are at the right place;

Just come and take test whenever you are free.....

We understand your pain that when you are going to register the test
you are not getting the slots available whenever you require.

So we have a solution for you:

1) The best place to take Prometric (like Microsoft, Sun Microsystems,
HP, IBM, Dell and many more) Test,

2) Any Time Exam facility: Take your test from Monday to Sunday,
Morning 07:00am till Evening 08:00pm,

3) Anytime up to 50 candidates can take up the test without any
disturbance at the same time,
Show full article (2.53Kb)
no comments
  wierd behavior in program         


Author: newbiegalore
Date: Feb 22, 2008 22:12

Hello everyone :-),
I am facing a small problem while coding
up a relatively simple program. I am reading a file with html tags in
it and am storing them in a character stack. The input file looks like
html
head
/head
/html

I read each tag and push it on the stack (cstack) and pop it when I
find the complimentary tag (/html for html and so on). I have declared
the stack as char* cstack[MAXSDEPTH] and assign a value to this...
Show full article (5.91Kb)
4 Comments
  arrays as function arguments         


Author: fkater
Date: Feb 22, 2008 14:58

Hi,

why doesn't calling f1 (see below) cause a warning while calling f2
does? Both seem to pass the wrong type. Is there another way to
declare f1 so that the caller is forced (warned) if the passed array
hasn't the same elements? I hope this is related to C and not a
question of the used compiler (here: gcc-4.1.2).

void f1(int a[4]){}
void f2(int (*b)[4]){}

int main(int argc,char** argv){

int c[4+1];
int (*d)[4+1];

f1(c); /* no warning */
f2(d); /* warning: incompatible pointer type */

return 0;
}

Felix
20 Comments
  Why not provide a standard non-busy waiting method?         


Author: mike3
Date: Feb 22, 2008 13:30

Hi.

Busy-waiting is a known anti-pattern that should be avoided. However,
in C,
there is no standard alternative, so when a wait is required and it's
not busy,
the program becomes 100%% non-portable. So then why not include this
type
of non-busy wait functionality in the standard?
28 Comments
  Pointer to small amount of storage         


Author: Old Wolf
Date: Feb 22, 2008 06:37

Is there undefined behaviour here:

#include

int main()
{
short *p = malloc( sizeof *p );
long *q = (long *)p;
q;

return 0;
}

Rationale being that evaluating q causes undefined
behaviour because q is neither null, nor pointing to storage
suitable for an object of type *q.

Assuming so; then is it undefined before the `q;' line, or
is the code valid and q indeterminate?
28 Comments
  hash from long url to short url         


Author: joe
Date: Feb 22, 2008 05:26

Hello anyone knows how to write a funtion to genereate a tiny url with
letters and numbers only. Something almost always unique. THanks.
12 Comments
  calloc interposing issue         


Author: reachanil
Date: Feb 22, 2008 02:30

Hi,

We've interposed malloc/calloc/realloc/memalign/valloc in our
application. While all of our application calls our own implementation
of these functions, there seems to be some issue with the dl.so shared
library (Windriver, ppc, linux 32 bit). The dl.so library defines a
function called - _dl_tls_setup and another one - _dl_deallocate_tls.
When our application that linked in -ldl and -lpthread, was shutting
down, we saw a crash with the backtrace pointing to
_dl_deallocate_tls. Upon further investigation we found that
_dl_tls_deallocate was calling 'free' which was our own implementation
(Not libc's) However, the chunk was got using malloc/calloc from
libc!!!!!. I put a breakpoint at _dl_tls_setup and found that it was
getting memory from the libc calloc.

I'm not sure how the dl library could have got calloc from libc and
free from our application. Please help!!!

thanks,
-Anil
6 Comments
  http://www.iq-test.pl/?d=3784         


Author: pantomek11
Date: Feb 22, 2008 02:21

no comments
  changing const variables         


Author: junky_fellow
Date: Feb 22, 2008 01:18

guys,

If I declare a const variable and then try to change it as follows;
const int i=5;
i = 10;

What would be the behaviour? Should compiler give compilation error or
Warning ?

Or, would I get a run time error (some exception as I am trying to
change a
const variable) ?

can compiler put const variables in read only memory ?

I tried this on multiple platforms using different compiler and I am
getting
different results, that is why I am asking this here.

I want to know the correct behaviour as per the standard C.

Again, thanks a lot for any help ...
2 Comments
  hai         


Author: gopi.suda
Date: Feb 22, 2008 00:30

hai

do u like me
*******************************************
http://microscope123.blogspot.com/

*********************************************
click this
no comments