|
by: deancoo |
last post by:
Hello all,
I have a class member, which calls another member from the same class. The
problem I'm experiencing is that the nested function executes fine, but
causes a segmentation fault as it exits. I've traced it to the point in the
code just before the line following the nested function is to be called, or
conversely right after the last line of the nested function.
What might be my problem? I'm hoping someone can give me some...
|
by: sandwich_eater |
last post by:
I get a segmentation fault in my program when resizing a vector. This
seems strange because it is the second resize that causes the error.
std::vector<double> a;
std::vector<double> b;
a.resize(ndata - 1);
b.resize(ndata - 1); // fault occurs here
|
by: Cocy |
last post by:
Hi,
This might be a sort of FAQ, but I don't see why,
so I would someone help me to understand what's wrong?
I've just created following code which wold trim
white space(s) in a (given) string.
But, it resulted the Segmentation fault, and so as
when running in gdb (saying "Program received signal
SIGSEGV, Segmentaion fault at *p++ = *st++").
The platform is Linux kernel 2.4.27, gcc version
|
by: francescomoi |
last post by:
Hi.
I've got a C program which calls a function:
----------------
printf("TEST1\n");
int value = my_function(param);
printf("TEST2\n");
int my_function(int my_param)
{
|
by: nae zot bba la |
last post by:
Hi, very short code here. Basically I want to open a file called
instruction in a++ mode and then write data of %s type to it, then read
from the same file and print to screen. The code compiles but when I
execute the binary and enter some string to expect the program to print
them for me to screen, segmentation fault occurs. Any ideas anyone?
#include <stdio.h>
#include <stdlib.h>
char *add;
|
|
by: silverburgh.meryl |
last post by:
Hi,
I have a segmentation fault in line 66 of GroupResult.h and I can't
figure out why that causes any problem, I appreciate if anyone can
help.
line 66 of Result.h:
66 size_t size() const { return _bdl.size(); }
|
by: Wes |
last post by:
I'm running FreeBSD 6.1 RELEASE #2. The program is writting in C++.
The idea of the program is to open one file as input, read bytes from
it, do some bitwise operations on the bytes, and then write them to
this second file. However, when the second file is 15360 bytes long,
the program dies with a "Segmentation Fault (core dumped)" error!
I checked with gdb, and it says the last function to run was memcpy()
from libc, which would...
|
by: krista |
last post by:
Hi,
I am beginner of C++. When I try to read a file and put it into X and
Y variables. I got that segmentation fault.
the data file is
data.txt:
4.4 6.8
3.2 -5.5
3.3 0.9
|
by: Brendan Wing |
last post by:
Howdy,
I was trying pass a file pointer from main to another function, so i can use the same file stream to perform certain task instead of closing stream on main then open a new one on the called function.
the code basically looks like this:
int func(FILE* pfile) {
//whatever task i need to perform
}
|
by: Charlie Starks |
last post by:
Please review my pastebin. I commented exactly where it occurs, and how GDB will not access my variable.
I made a program to prove that you can store an address into an unsigned int and use it as a pointer. It works on old 32bit machine, but not on my 64 bit. I can only assume it is because of my compiler??
//I am trying to figure out why I get a segmentation fault at "*((char *) hacky_nonpointer)"
//
//This works on a 32 bit older gcc...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|