>A variable length array?
Yes, it is integer array that size is know at runtime.
>You're passing pointers to local variables - when the variable goes out of scope your thread is using unallocated...
Type: Posts; User: gandalf_bar
>A variable length array?
Yes, it is integer array that size is know at runtime.
>You're passing pointers to local variables - when the variable goes out of scope your thread is using unallocated...
Hi, I have problem with my code. In Fedora Core 4, I could compile and run it. Then I changed distro to Ubuntu Breezy Badger ( 5.10 ). I can compile it and when I run it, I get segmentation fault.
...
Hi,
I made application using C++ in Linux in my computer ( 32 bit ). Once upon a time, a user installed it in 64 bit system. He tried to run it. Segmentation fault. No error message. No warning...
Thank you, Salem! That explain why my application got weird error beside this. When encounter certain wallpaper, it output: Error: Text contain invalid UTF-8 or something like that but does not make...
Hi,
I develop program to change wallpaper in Gnome desktop. The program is simple but depend on three or four uncommon library. So it does not make sense if I post my program here. This was the...
I learned pthread_cond_timedwait from here:
http://users.actcom.co.il/~choo/lupg/tutorials/multi-thread/multi-thread.html#thread_condvar_wait
Here is the "make me confuse" code:
while...
Ok, I change the code to:
#include <pthread.h>
#include <iostream>
#include <vector>
using namespace std;
vector<string> myVector[3];
vector<string>::iterator myVectorIterator;
Hi,
Here is the code:
#include <pthread.h>
#include <iostream>
#include <vector>
using namespace std;
Hi, there is a binreloc.....
http://autopackage.org/docs/binreloc/
With this binreloc, you can get the full path of you application. I can compile a simple c program with this binreloc just like...
Got the answer....
http://autopackage.org/docs/binreloc/
Hi....
Assume I have this directory: /opt/blabla
Inside it there are: bla ( executable file ) and resource.txt ( resource file needed by bla )
$ cd /opt/blabla
$ ./bla
Everything runs fine......
Hi Ken,
I have tried your code and this:
#include <windows.h> //You need shell32.lib for this one
int main(void)
{
char szPath[] = "jre1.5.0\\bin\\java.exe";
I have read the faq before I post my question, Salem....
system() always make the console appears......
I try to use CreateProcess function. Here's the code:
#include <windows.h>
int...
Hi, I try to run a java application by exe file.....
Here's the code:
#include <stdio.h>
#include <process.h>
int main(void)
{
Callback function? I m sorry. I never heard about this one. I know about mutex, conditional variables but not this. Yes, I refer to posix implementation.
I have just read chapter about threads and I just want to ask quick question. What is the best way to pass data from threads to main process? Is it using global variables ( and of course using mutex...
The best way to learning something is to practicing....... it......
Make the project.....
Make something useful....
You learn a lot from there......
Got it! I have to do this way:
g++ -o hello hello.cpp -I /path/to/include -L /path/to/lib -lpthread -lxerces-c
And in the file I have to put this statement:
XERCES_CPP_NAMESPACE_USE
Very...
Ok, I try to make application using xml library. My configuration data will be stored in xml files. So....
I downloaded library from here:
http://xml.apache.org/xerces-c/index.html
Ok, I have...
Thank you, guyz! Now I understand it very much......
The problem is.... when I use your approach.... :
00:00, I am in ws 2.... my wallpaper is Superman.jpg now.
If I wait for 60 seconds ( my daemon sleep for 60 seconds ) and I don't change ws, that...
Beginning Linux Programming???? That is very good. From wrox, isn't it? I give two thumbs up.
Hey, quzah...... take it easy.....
please look at the post before your post.......
calm down. There is no need to waste energy with my dumbness.
Ok, since I made the dumbest post, I have to fix it. Consider this code:
#include <iostream>
using namespace std;
int main()
{
for( int i = 0; i < 4; i++ )
{
oh, yeah, you right. I never check it before. I thought it cann't because variable i cannot be use after for statement.
The dumbest post I have ever made. :(