f



PThreads on Linux 2.4 and 2.6

--nextPart1313254.DHcRQgtn85
Content-Type: text/plain; charset=iso-8859-15
Content-Transfer-Encoding: 8Bit

Hi People!

I have written a small echo server with pthreads for my studies.
The program (attached) runs fine under linux 2.4 (debian stable)
and does what it shall do (bind, listen, accept in main thread,
read/write in child-thread).
If i run the same binary under linux 2.6 (debian unstable) the 
server binds, listens and accepts, but accept() returns -1, and
pthread_pid() returns a big negative number in the child-thread.

i read the web for some hours but find no solution...
what is the difference between linux 2.4 and 2.6 ?

-- 
 MfG, Christian Welzel aka Gawain@Regenbogen

  GPG-Key:     http://www.camlann.de/key.asc
  Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
--nextPart1313254.DHcRQgtn85
Content-Type: text/x-c++src; name="echod.c"
Content-Transfer-Encoding: 8Bit
Content-Disposition: attachment; filename="echod.c"

/* Multi-threaded echo-Server */

#include <stdio.h>
#include <pthread.h>
#include <signal.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>

static struct sockaddr_in local;
static struct sockaddr_in remote;

extern int errno;

// Schutzmutex fuer Thread-Liste
static pthread_mutex_t list_mutex;

// Element der Thread-Liste
struct th_list {
	struct th_list *next;
	struct th_list *prev;
	int socket;
	pthread_t th;
};

// Beginn der Thread-Liste
static struct th_list *th_first;

// Testfunktion fuer IO-Calls
void test(int retval,char *text)
{
	if (retval < 0) {
    	perror(text);
		exit(1);
	}
}

// Server initialisieren
int initServer() {
	int s, b;

	/* Create an endpoint for communication */
	s = socket(PF_INET, SOCK_STREAM, IPPROTO_IP);
	test(s, "Could not create socket!");

	/* Initialisieren des Sockets */
	local.sin_family = AF_INET;
	local.sin_port   = htons(7007);
	local.sin_addr.s_addr = INADDR_ANY;

	remote.sin_family = AF_INET;
	remote.sin_port   = htons(7007);

	// an Socket s binden
	b = bind(s, (struct sockaddr *) &local, sizeof(local));
	test(b, "Could not bind to socket!");

	return s;
}

void echoServCleanup(void *args) {
	struct th_list *p = (struct th_list *) args;
 
	printf("echoServCleanup: %d\n", p->socket);
	close(p->socket);

	pthread_mutex_lock(&list_mutex);
	if(p->prev) p->prev->next = p->next;
	if(p->next) p->next->prev = p->prev;
	if(th_first==p) th_first = p->next;
	pthread_mutex_unlock(&list_mutex);
	free(p);
}

// Der Echo-Thread
void *echoServ(void *args) {
	struct th_list *p;
	char buf[1022];
	char buf2[1024];
	int len;

	p = (struct th_list *) args;

printf("%p\n",args);

	pthread_setcanceltype(PTHREAD_CANCEL_ENABLE, NULL);
	pthread_setcancelstate(PTHREAD_CANCEL_DEFERRED, NULL);

	printf("thread %d started with socket %d\n", (int)pthread_self(), p->socket);

	pthread_cleanup_push(echoServCleanup, p);

	memcpy(buf2, "S:", 2);

	while(1) {
		memset(buf, 0, 1022);
		memset(buf2+2, 0, 1022);
		pthread_testcancel();
		len = read(p->socket, buf, 1022);
		printf("   Read %d bytes: %s\n", len, buf);
		if(len <= 0) break;
		strcat(buf2, buf);
		write(p->socket, buf2, len+2);
		printf("   Wrote %d bytes: %s\n", len, buf2);
	}

	pthread_cleanup_pop(1);

	return NULL;	
}

// das Hauptsocket des Programmes
static int my_socket;

// Aufraeumen der Datenstrukturen beim exit()
void my_exit(void) {
	printf("Closing socket...\n");
	close(my_socket);

	printf("Canceling threads...\n");
	while(th_first) {
		printf("Waiting for thread %d...\n", (int) th_first->th);
		pthread_cancel(th_first->th);
		pthread_join(th_first->th, NULL);
	}
	printf("Exit.\n");
}

// Abfangen von Strg-C
void my_int(int s) {
	// hack um das verteilen des exit() bei SIGINT an die threads zu verhindern
	printf("Strg-C: %d\n",(int)pthread_self());
//	if((int)pthread_self()!=16384) return; 
	exit(s);
}

// main() funktion
int main(int argc, char **argv) {
	int r_socket;  // der Socket nach dem accept
	socklen_t len;
	struct th_list *th;   // Thread-Lsiten-Eintrag

	printf("To abort the echo deamon press Ctrl-C.\n");

	atexit(my_exit);          // Abfangen, um aufzuraeumen
	signal(SIGINT, my_int);   // dito
	my_socket = initServer(); // Sockets initialisieren

	listen(my_socket, 10);

	th_first = NULL;
	while(1) {
		r_socket = accept(my_socket, (struct sockaddr *) &remote, &len);
		printf("Socket: %d -> %d\n", r_socket, errno);
		th = malloc(sizeof(struct th_list)); // neues Thread-Listen-Element erschaffen
		th->socket = r_socket;
		pthread_mutex_lock(&list_mutex);  // Element einketten
		th->prev = NULL;
		th->next = th_first;
		if(th_first) th_first->prev = th;
		th_first = th;
		pthread_mutex_unlock(&list_mutex);
		pthread_create(&th->th, NULL, echoServ, th); // Thread starten
	}

	return 0;
}

--nextPart1313254.DHcRQgtn85--
0
Christian
11/21/2004 7:17:36 PM
comp.programming.threads 4878 articles. 1 followers. Post Follow

9 Replies
637 Views

Similar Articles

[PageSpeed] 17

Guten Morgen Christian,

> I have written a small echo server with pthreads for my studies.
> The program (attached) runs fine under linux 2.4 (debian stable)
> and does what it shall do (bind, listen, accept in main thread,
> read/write in child-thread).
> If i run the same binary under linux 2.6 (debian unstable) the 
> server binds, listens and accepts, but accept() returns -1, 

Which errno code is returned?


> and pthread_pid() returns a big negative number in the child-thread.

Yes, that's normal. A thread id is an opaque type. Though /pthread_t/ is 
cast to long on Linux, what's inside is implementation dependant. I 
suspect that your Debian/Linux 2.4 is using LinuxThreads, whereas your 
Debian/Linux 2.6 NPTL. With NPTL, the pthread_t is in fact a pointer to 
thread local storage (AFAIK).

Generally, you can't make any assumption about /pthread_t/.

> i read the web for some hours but find no solution...
> what is the difference between linux 2.4 and 2.6 ?

See above. But NPTL should have no influence on /accept()/. That's why 
printing out the errno number/error string description could be useful.

A last thing. The way you catch SIGINT is not what you want to do in a 
multi-threaded code. And note aside, you can't legally call /printf()/ 
in your signal handler since you are calling /printf()/ elsewhere, and 
/printf()/ is not async-signal-safe. [ the net effect of this is that 
you might under some circumstances deadlock on Linux when typing Ctrl-C ].


Hope this help,
Loic.
0
Loic
11/22/2004 6:37:35 AM
Loic Domaigne wrote:

> Which errno code is returned?

As you can see in the code, i already thought of this, and have 
a printf(errno) in  my code... but this printf always shows a "0",
that is, what  i wonder about.

My code gives the following lines of output:
To abort the echo deamon press Ctrl-C.
Socket: -1 -> 0
0x804b050
thread 16386 started with socket -1
   Read -1 bytes:
echoServCleanup: -1

But the main thread is furthermore accepting connections, that
of cause show the same behavoir than.

> Generally, you can't make any assumption about /pthread_t/.

Yeah, i know that, but i thought, that could be a hint...
 
> See above. But NPTL should have no influence on /accept()/. That's why
> printing out the errno number/error string description could be useful.

See above.
accept() returns -1, but the errno is 0.
 
> A last thing. The way you catch SIGINT is not what you want to do in a
> multi-threaded code. 

What way would you suggest ?

> >And note aside, you can't legally call /printf()/ 
> in your signal handler since you are calling /printf()/ elsewhere, and
> /printf()/ is not async-signal-safe. [ the net effect of this is that
> you might under some circumstances deadlock on Linux when typing Ctrl-C ].



> 
> 
> Hope this help,
> Loic.

-- 
 MfG, Christian Welzel aka Gawain@Regenbogen

  GPG-Key:     http://www.camlann.de/key.asc
  Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
0
Christian
11/22/2004 7:31:08 AM
Christian Welzel <gawain@camlann.de> writes:

> a printf(errno) in  my code... but this printf always shows a "0",
> that is, what  i wonder about.

Never do this:

> extern int errno;

Do this instead: '#include <errno.h>', and see if the answer changes.

> My code gives the following lines of output:
> To abort the echo deamon press Ctrl-C.
> Socket: -1 -> 0
> 0x804b050
> thread 16386 started with socket -1

You told us "pthread_pid() returns a big negative number".
Did you collect the output above on the "wrong" machine?

FWIW, your code "works" on Fedora Core3.

Also note that you are joining your threads only at exit. This
means that your server will have 1000 threads "hanging around" and
doing nothing after 1000 clients have connected and disconnected
from it.

Cheers,
-- 
In order to understand recursion you must first understand recursion.
Remove /-nsp/ for email.
0
Paul
11/22/2004 3:29:31 PM
"Christian Welzel" <gawain@camlann.de> wrote in message 
news:30c7ueF2urtnkU1@uni-berlin.de...

    Try fixing all your bugs. :) For example:

  len = read(p->socket, buf, 1022);
  printf("   Read %d bytes: %s\n", len, buf);
  if(len <= 0) break;
  strcat(buf2, buf);

    The 'strcat' function requires a C-style string; however, 'buf' is not a 
C-style string at this point.

    DS


0
David
11/22/2004 4:42:39 PM
David Schwartz wrote:

>     Try fixing all your bugs. :) For example:
>     The 'strcat' function requires a C-style string; however, 'buf' is not
>     a C-style string at this point.

In most cases it is. 
Only in case, the input from read is exactly 1022 byte long, its not.
I fixed that off by one error.

-- 
 MfG, Christian Welzel aka Gawain@Regenbogen

  GPG-Key:     http://www.camlann.de/key.asc
  Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
0
Christian
11/22/2004 6:20:59 PM
Paul Pluzhnikov wrote:

> Do this instead: '#include <errno.h>', and see if the answer changes.

Thanks for that hint. it fixed at least the errno issue :)
Now accept() returns -1 and sets errno to 22
(#define EINVAL      22  /* Invalid argument */)

How can an argument to accept() be invalid ?

> You told us "pthread_pid() returns a big negative number".
> Did you collect the output above on the "wrong" machine?

I dont think so, because i tested it only on two machines...
on one it worked, on the other it didn't.

Here is the output after the errno-fix:

To abort the echo deamon press Ctrl-C.
Socket: -1 -> 22
0x804b008
thread -1209459792 started with socket -1
   Read -1 bytes:
echoServCleanup: -1

As you can see, there are this big negative numbers again for
pthread_self().
 
> Also note that you are joining your threads only at exit. This

Thanks for that, i'll fix it.

-- 
 MfG, Christian Welzel aka Gawain@Regenbogen

  GPG-Key:     http://www.camlann.de/key.asc
  Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
0
Christian
11/22/2004 6:28:55 PM
Christian Welzel wrote:
> Paul Pluzhnikov wrote:
> 
> 
>>Do this instead: '#include <errno.h>', and see if the answer changes.
> 
> 
> Thanks for that hint. it fixed at least the errno issue :)
> Now accept() returns -1 and sets errno to 22
> (#define EINVAL      22  /* Invalid argument */)
> 
> How can an argument to accept() be invalid ?

Read the man page! Try len = sizeof(remote) before accept().

> 
> 
>>You told us "pthread_pid() returns a big negative number".
>>Did you collect the output above on the "wrong" machine?
> 
> 
> I dont think so, because i tested it only on two machines...
> on one it worked, on the other it didn't.
> 
> Here is the output after the errno-fix:
> 
> To abort the echo deamon press Ctrl-C.
> Socket: -1 -> 22
> 0x804b008
> thread -1209459792 started with socket -1
>    Read -1 bytes:
> echoServCleanup: -1
> 
> As you can see, there are this big negative numbers again for
> pthread_self().
>  
> 
>>Also note that you are joining your threads only at exit. This
> 
> 
> Thanks for that, i'll fix it.
> 
0
Luke
11/22/2004 7:19:02 PM
Luke Elliott wrote:

> Read the man page! Try len = sizeof(remote) before accept().

Ok, i inserted this before accept() and now the whole stuff works.
many thanks !
But in my manpage there is :
"it should initially contain the size of the structure pointed to by addr".
There is nothing written of *must* and with kernel 2.4 is works
without it. 

-- 
 MfG, Christian Welzel aka Gawain@Regenbogen

  GPG-Key:     http://www.camlann.de/key.asc
  Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
0
Christian
11/22/2004 8:03:18 PM
Hallo Christian,

>>Read the man page! Try len = sizeof(remote) before accept().
> 
> 
> Ok, i inserted this before accept() and now the whole stuff works.
> many thanks !
> But in my manpage there is :
> "it should initially contain the size of the structure pointed to by addr".
> There is nothing written of *must* and with kernel 2.4 is works
> without it. 

Unfortunately, the man page are not always 'up to date'. The manual you 
want to consult in such cases is the "Single Unix Specification, 2004 
Edition" standard.

Cheers,
Loic.
0
Loic
11/23/2004 5:39:07 AM
Reply:

Similar Artilces:

TRSDOS II, version 4.2.0, 4.2.2, 4.2.4, 4.2.6 (or 4.3.x or 4.4)
Hi, Group I require a copy of the above DOS, but I need it _on disk_ as I do not have an emulator for the Model II that must be tested. Is there any possible sources of the OS on disk, or can you advise if the original 8" drive can be hooked to another device so that I can transfer an electronic copy to the disk to boot the machine? What other options do I have? Thanks L replying to my own post :-) I found an article here (http://www.tim-mann.org/trs80resources.html) where Tim describes a trick to rescue a disk's contents. This should be a workable solution...

Does 4/2/2= (4/2)/2 =1 OR = 4/(2/2)=4
I don't have matlab and I am trying to translate some simple matlab code. Does 4/2/2 = (4/2)/2 = 1 or 4/2/2 = 4/(2/2) = 4 On 9/11/2012 9:43 AM, sarah.englander@gmail.com wrote: > I don't have matlab and I am trying to translate some simple matlab code. > > Does 4/2/2 = (4/2)/2 = 1 yes. At a given precedence level (and obviously two of the same operators are the same level) evaluation proceeds from LtoR. ....snip... <http://www.mathworks.com/help/techdoc/matlab_prog/f0-40063.html#f0-38155> -- dpb <none@non.net> wrote in message <...

Upgrade of Xalan 1.2.2 and Xerces 1.4.4 to Xalan 2.6 and Xerces 2.6.2
I've been tasked with upgrading the JVM from 1.3 to 1.4, and the third party libraries used by my company on our existing Java framework. I'm most worried about any problems that may occur due to upgrading Xalan and Xerces as our framework performs much XML transformation and processing. Does anyone have a link to known issues with such an upgrade (besides the Xalan / Xerces sites) ? Or has anyone done such an upgrade and can share their pearls of wisdom? Thanks Chris ...

how to upgrade from linux 2.4 to 2.6? and RamDisk #2
how to upgrade from linux kernel 2.4 to 2.6 on arm? and how to build RamDisk? ...

[News] Speech Recognition Software/SDK for Linux (2.2, 2.4, 2.6 Kernel)
Fonix Releases Linux-Supported Automatic Speech Recognition Technology ,----[ Quote ] | "The end result is an SDK with considerably higher rates of speech | recognition and greater usability as a language learning tool." `---- http://in.sys-con.com/read/280838_p.htm ...

Upgrade from VO 1 - 2 - 2..1 -2.2 - 2.3 -2.4 - 2.5 - 2.6 - 2.7
About upgrade 2.5 - 2.7 at $ 384.00 For most products I'm using - the updates (2.0 - 2.1 - 2.7) are free... 2.0 to 3.0 might be worth + 10-30% of the original price? VO is + full price again & again - Full program price for every minor upgrade/bug-fix? I dropped out of the money/bugs [VO] at 2.5 after starting at 1.0 more than 10 years ago. Certainly whoever is making VO have to make a living; earning moneys: - that is OK! A 10 years old VO site; - 10 years later, how much have changed? http://www.yi.com/prany/cavo/cavofront.htm Even MS is not ...

[wx 2.6, Debian Linux, g++ version 4.1.2] threads and dialogs
------=_Part_27604_22490567.1191899440307 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline Hi, I've been doing some multi-threaded wxWidgets programming for a networked application, and so far it has been working fantastically. However, I have recently been foiled by the following snippet of code: wxString choice=::wxGetSingleChoice(_T("Select a dog for the user to connect to."), _T("Dog Selection for New User"), arr, this); where 'arr' is a wxArrayString with names in it. T...

2 * 2 * 2 * 2 or pow(2, 4)?
Hi , I hope this isn't too trivial to ask, but I'm evaluating a polynomial that involve lots of terms like x^2y^2z^3, and although I can use the power function pow(a, b), I wonder if just writing x*x*y*y*z*z*z for example wouldn't be more efficient than pow(x, 2)*pow(y, 2)*pow(z,3). Or is it all the same? Thanks, - Olumide Olumide wrote: > I hope this isn't too trivial to ask, but I'm evaluating a polynomial > that involve lots of terms like x^2y^2z^3, and although I can use the > power function pow(a, b), I wonder if just writing x*x*y*y*z*z*z for > exam...

threads 2.6.2 on linux x86_64: thread::create hangs
Hello all and Zoran ;-), on a Fedora Core 4 installation, with (recompiled) tcl 8.4.12: $ strace tclsh % package require Thread 2.6.2 % thread::create .... write(1, "% ", 2% ) = 2 read(0, thread::create "thread::create\n", 4096) = 15 mmap(NULL, 10489856, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS|0x40, -1, 0) = 0x40a01000 mprotect(0x40a01000, 4096, PROT_NONE) = 0 clone(child_stack=0x41401270, flags=CLONE_VM|CLONE_FS|CLONE_FILES|CLONE_SIGHAND|CLONE_THREAD|CLONE_SYSVSEM|CLONE_SETTLS|CLONE_PARENT_SETTID|CLONE_CHILD_CLEARTID|CLONE_DETACHED, ...

how to go back from 2.6.4 to 2.6.2 under windows ?
hello, I've just upgraded my system from Python 2.5 to 2.6.4, and installed the latest packages of a lot of libraries. Now one essential package (VPython) only works with Python 2.6.2. I tried to install Python 2.6.2 over this 2.6.4 installation, and indeed the readme file says it's 2.6.2, but the python and pythonw are still 2.6.4. Why is that so ?? Now assume that a number of packages (because compiled with 2.6.4) will not work correctly with 2.6.2. Is that correct ? So the best way would be to reinstall everything ?? thanks, Stef Mientki ...

sleep() API behaves differently in Linux 2.4 and Linux 2.6
Hi, I have a simple program utilizing "sleep()" api to sleep 3 msec periodically. I measured the time difference before calling the api and after it returns back. The same application behaves differently running on Linux 2.4 and 2.6 In Linux 2.6.11, it takes about 3 msec, and running on Linux 2.4.20 it takes about 10 msec. I have attached the program below, many thanks in advance. #include <stdlib.h> #include <stdio.h> #include <sys/types.h> #include <sys/time.h> #include <time.h> #define TO_64(a) (a##LLU) #define kUsecTimeScale TO_6...

RE: wxGTK 2.4.2 / GTK+ 2.6.2 Drag and Drop locks up #2
Hello again, everyone: For what it's worth, Making a call to gdk_pointer_ungrab() immediately after the call to wxDropSource.DoDragDrop() seems to have at least worked around our DnD locking up problem. Thanks to Vadim and everyone else who helped with this. Regards, Chris --------------------------------------------------------------------- To unsubscribe, e-mail: wx-users-unsubscribe@lists.wxwidgets.org For additional commands, e-mail: wx-users-help@lists.wxwidgets.org ...

Crash when using wxTextCtrl with xwGTK-2.4.1 and wxGTK-2.4.2 Suse Linux 8.2
I am using trying to add some wxTextCtrl to a frame with the result that the program crashes when starting it. On console the errormessage is (in german) Speicherzugriffsfehler (Don't know what an english Linux would give out-> It means imho that an address is accessed that does not depend to the applications memory space.) It compiles without errors, I tried GTK-2.4.1 & 2.4.2 with the same result. (wxWindows is compiled without GTK2 support !) The code that doesn't work with Linux works on Windows. (9x) I found out that for any strange reason when I add the li...

ANNOUNCE: Tcl/Tk 8.4.6 rpm specification with thread 2.5.2 extension #2
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 http://jfontain.free.fr/tcltk-8.4.6-2.spec Generated and tested on an up-to-date Red Hat Fedora Core 1 i386 system. The rpms install under /opt/tcltk and therefore do not conflict and peacefully coexist with the stock Redhat Tcl and Tk rpms. To build the rpms, download the Tcl/Tk 8.4.6 and Thread 2.5.2 sources from http://download.sourceforge.net/tcl/ into the /usr/src/redhat/SOURCES/ directory, place the specification file in the /usr/src/redhat/SPECS/ directory, then from that directory, type: ~ # rpmbuild -bb --clean tcltk-8.4.6-2.spec Note...

mmap/munmap frustration in 2.6/2.4/2.2 kernels
My driver makes available three resources for mmap/munmap operations. 1. PCI device registers 2. A DMA buffer for read operations whose size is configured by the application. 3. A DMA buffer for write operations whose size is also configured by the application. My test application contains a loop that repeatedly does the following: 1. Opens the device 2. Performs various tests involving mmap/munmap of the vrious resources. 3. Closes the device 4. Repeat loop per command line arguments. On all three kernels I can successfully run millions upon millions of iterations where I ...

ANN: ActivePython 2.6.2.2, 3.1.0b1.0, 2.5.4.4 is now available
I'm happy to announce that ActivePython 2.6.2.2, 3.1.0b1.0 and 2.5.4.4 are now available for download from: http://www.activestate.com/activepython/ This is a patch release that updates ActivePython to core Python 2.6.2 and 3.1b2. This release also contains updates to Tcl/Tk 8.5.7 and Tix 8.4.3. We recommend that you try 2.6 version first. See the release notes for full details: http://docs.activestate.com/activepython/2.6/relnotes.html What is ActivePython? --------------------- ActivePython is ActiveState's binary distribution of Python. Builds for W...

ANN: ActivePython 2.6.2.2, 3.1.0b1.0, 2.5.4.4 is now available
I'm happy to announce that ActivePython 2.6.2.2, 3.1.0b1.0 and 2.5.4.4 are now available for download from: http://www.activestate.com/activepython/ This is a patch release that updates ActivePython to core Python 2.6.2 and 3.1b2. This release also contains updates to Tcl/Tk 8.5.7 and Tix 8.4.3. We recommend that you try 2.6 version first. See the release notes for full details: http://docs.activestate.com/activepython/2.6/relnotes.html What is ActivePython? --------------------- ActivePython is ActiveState's binary distribution of Python. Builds for Windows, Mac OS X,...

what is 4.2.2.2
Hi I came to found from many websites when i had a problem in Internet explorer when if i browse any websites, its showing me "Page cannot be displayed" and in bottom of the page it shows "Cannot find server or DNS Error" Internet Explorer that they advised me to put 4.2.2.2 in my Primary DNS Server. I am in DHCP enabled Network and using windows xp sp2. My question is what is this ip address mean (4.2.2.2) ? Pl explain in detail. Can we give it in our Primary DNS server ? Thanks in advance Chandra -- chandra Message posted via HWKB.com http:...

wxPython 2.4.2.4 segmentation fault on (Python 2.2.2 SuSE 8.2)
Hi everything runs normally but exiting demo.py or any app we get Segmentation Fault wxPython was built from sources (as per readme.1st.txt) as latest downloaded from wxPython site while building wxGTK several errors reported as could not read from makefile.in files please assist Sanjay Minni Note that we used GTK1 i.e. compiled without the GTK2 option on SuSE 8.2 Thanks Sanjay Minni ...

different maximum Java -Xmx on kernel 2.6.9 (RedHat 4 update 2) and 2.6.22 (CentOS 5.2)
Hi, I recently upgraded a 32bit RedHat 4 machine (with 4GB RAM) with kernel 2.6.9 to CentOS 5.2 32bit. When it was still on RedHat I was able to run a Java application with the -Xmx3500m flag. However on CentOS with kernel 2.6.22, it does not allow me to reserve more than - Xmx2622m. Can anyone please explain to me why this is and how I can get it to work with 3500m? Thanks! At Sun, 29 Mar 2009 09:02:15 -0700 (PDT) mail2joni@gmail.com wrote: > > Hi, > > I recently upgraded a 32bit RedHat 4 machine (with 4GB RAM) with > kernel 2.6.9 to CentOS 5.2 32bit. When it was still on...

different maximum Java -Xmx on kernel 2.6.9 (RedHat 4 update 2) and 2.6.22 (CentOS 5.2)
Hi, I recently upgraded a 32bit RedHat 4 machine (with 4GB RAM) with kernel 2.6.9 to CentOS 5.2 32bit. When it was still on RedHat I was able to run a Java application with the -Xmx3500m flag. However on CentOS with kernel 2.6.22 (PAE), it does not allow me to reserve more than -Xmx2622m even though 'free' shows that there is enough memory available: # free total used free shared buffers cached Mem: 4074980 161636 3913344 0 13740 117696 -/+ buffers/cache: 30200 4044780 Swap: 2031608...

RE: Re[3]: wxGTK 2.4.2 / GTK+ 2.6.2 Drag and Drop locks up #2
Kevin - I'd love to do just that (I've already built 2.5.3 and am perusing the CVS logs for deltas as I compose this), but my boss(es) are big on only deploying 3rd-party libraries which have been blessed as "stable" to our customers (yes, I'm on a commercial endeavor), and it's hard for me to blame them from a risk standpoint. I look forward to 2.6 (or whatever is to be the next stable release). To that point - can someone point me to the policies/criteria/processes/thresholds/heuristics for deeming a particular release as a "snapshot" or "st...

wxMac 2.6.2: SetBackgroundColour not working on wxStaticText, worked on 2.4.2
Hi all, I'm upgrading an application from 2.4.2 to 2.6.2. So far everything's been going very well, except for this one last issue. I have a wxStaticText item in a wxPanel. I cal SetBackgroundColour and I get the standard 3D ribbed background instead. The foreground color for the text works fine, but not the background color. I checked that the base control has the proper brush type and color set. If I call SetBackgroundColour on the wxPanel or the wxTreeCtrl I get a background color, just not a wxStaticText. I searched allthrough the documentation, the source code, called a...

need to migrate from Linux 2.4 to Linux 2.6 kernel, direct replacement of kernel image is Ok?
Currently using one of the leading Embedded Distribution on MIPS core based processor, this Linux is 2.4.20 Kernel, some customers also doing trails with this platform, but some new customers are interested with 2.6 kernel version, can we download 2.6 kernel version from kernel.org and make necessary changes whatever did for 2.4 and replace old kernel file "vmliux.gz.img" with new image, will it be Ok?, not sure how IP address conversion and all migrate, current 2.4 load, we are using dnsmasq package as DHCP/DNS server, which assignes 4 byte IP address on LAN side, any chang...

Web resources about - PThreads on Linux 2.4 and 2.6 - comp.programming.threads

C - Skills - LinkedIn
See top C professionals, groups, and related job openings.

John Paul Titlow (@johnpaul) on Twitter
Sign in Sign up You are on Twitter Mobile because you are using an old version of Internet Explorer. Learn more here John Paul Titlow @ johnpaul ...

Lock (computer science) - Wikipedia, the free encyclopedia
Generally, locks are advisory locks , where each thread cooperates by acquiring the lock before accessing the corresponding data. Some systems ...

Job Interview at Apple
Navigation Menu Home Adobe Amazon Apple AT&T Bank of America Citrix Dell eBay Electronic Arts Facebook Google Hitachi HP IBM Intel Intuit McDonalds ...

Parallel BZIP2 (PBZIP2)
... implementation of the bzip2 file compressor PBZIP2 is a parallelimplementation of the bzip2 block-sorting file compressor that uses pthreadsand ...

Arduino Usertools simple threading, simple user interface, powerful debugging - Arduino Forum
Arduino Usertools simple threading, simple user interface, powerful debugging

SENIOR SOFTWARE DEVELOPMENT ENGINEER
SENIOR SOFTWARE DEVELOPMENT ENGINEER job in BALTIMORE, Maryland, US. Read the SENIOR SOFTWARE DEVELOPMENT ENGINEER job description and find other ...

UNIX INTERNATIONAL REVIEWS THE UNIX SYSTEM V.4 STORY SO FAR
Unix International Inc says that its Unix System V.4 EnhancedSecurity Multi-processing - ES/MP - effort will coalesce variousprojects that have ...

书籍搜索: Peter Bil
... 搜索结果121-135 共64057 The Family Circus by Request Keane, Bil / Ideals Pubns / 2004-1 / $ 14.63 ( 少于10人评价 ) Multithreaded Programming With PThreads ...

Making the Most of Multi-Core Processors: Part 1
In Part 1 of a series of articles, the QNX authors evaluate the two most popular multiprocessing models - symmetric (SMP) and asymmetric (AMP) ...

Resources last updated: 3/3/2016 10:32:06 AM