Programming :: Safe Free() In Gcc?

Dec 30, 2010

under windows, when i call free() on a non-pre-allocated char pointer nothing happens, but when i do the same call under linux the whole application crashes :/

is there anyway to avoid crashing? safe free() call that does nothing when fail?

View 5 Replies


ADVERTISEMENT

Fedora :: Download Free Pen Drive Virus Scanner - Make Computer Safe?

May 1, 2010

How can i download free pen drive virus scanner? I need good one? Most of computer gets attacked by viruses through flash drives or usb drives or pendrives. If we can scan and delete it before using it we can make our computer safe.

View 3 Replies View Related

Programming :: Free-ing Memory - C/C++ - Free()

Jan 29, 2010

Here is the code, which just creates a dynamic array? fills it? and prints.

At the end-point? when doing 'free(digits);' I get a debug messge. But the programm continues to work, or it crashes only on free?

How do I need to change the source-code, not to recieve a message from debugger?

View 6 Replies View Related

Programming :: Is Popen Thread Safe Via Pthreads?

Sep 17, 2010

I don't seem to find a conclusive answer to this one...."Is popen thread safe via pthreads?"

View 2 Replies View Related

Programming :: Writing PHP Code - Safe To Install Xampp?

Dec 16, 2010

What do I need to start writing some php code? I've seen some tutorials where they install xampp, but I see it installs php, mysql and other stuff, my slackware already has mysql, so I don't know if installing xampp would cause some conflicts. What do I need to install considering that I already have mysql?

View 2 Replies View Related

Programming :: Saving File Data Using Python In An Embedded System In An Safe And Fast Way?

Apr 19, 2011

I am developing a program in a system where the Linux does not take care of the sync command automatically. So I have to run it from my application always I save some data in the disk, which in my case is a 2GB sdcard. It is true that I can make the operation system takes care of the syncronization, using a proper mount option, but in this case the programm's performance drops drastically. In particular I use the shelve module from Python to save data that comes from a socket/TCP connection and I have to deal with the potencial risk of the system being turned off suddenly Initially I wrote something like that to save data using shelve:

Code:

def saveData(vo)
fd = shelve.open( 'fileName' , 'c')
fd[ key ] = vo
fd.close()
os.system("sync")

But that takes too much time to save the data. Note that I use the sync from the OS every time I close a file to prevent data corruption in the case of the "computer" being turned off with data even in the buffer. To improve the performance I made something like that:

Code:

def saveListData( list )
fd = shelve.open('file_name', 'c')
for itemVo in list:
fd[itemVo.key] = itemVo
fd.close()
os.system("sync")

Thus, first I saved an amount of objects in a list then I open the file and save the objects. In this way I have to open the file just one time to save a lot of objects.However I would like to know if adding a lot of objects before closing the file would increase the risk of data corruption.I known that turning off the system after fd.close() and before os.sync may cause problems. But what about turning off the system after

Code:

fd = shelve.open('file_name', 'c')

but before fd.close()?

View 7 Replies View Related

Programming :: Is Java Free For Use For Business Purpose

Dec 28, 2010

I learned Java(SE,EE) few years ago and didn't use it because we are using PHP and ASP.NET at work.However, I would like to ask a question: Is Java (SE,EE) free for use for business purpose?I mean,if I start up a company and use tomcat with java, do I have to pay for the license to use Java?I don't know much about java license until I learned that ASF(Apache Software Foundation) quited from the Java Community recently.As a result,they recalled my attention regarding the legitimacy of using java in business purpose for free.

View 9 Replies View Related

Programming :: MATLAB - Any Valid Free Alternatives?

Mar 2, 2010

I need MatLab for a course at the university, but it's not an open source software as all of you know, so I wanted to know if there are valid freeware alternatives. I was told to use Octave or Scilab if I didn't want to buy the license and so I would like to know what's better in terms of MatLab compatibility and ease of use, if there are any other (and maybe better) alternatives and also if there are free Simulink-like programs.

View 8 Replies View Related

Programming :: Hooking Calls To New/malloc Delete/free?

Jan 11, 2010

Is there a way to hook calls to new/malloc, delete/free in C++? I tried the following methods: LD_PRELOAD -> fails for malloc, because dlsym seems to depend on malloc -Wl,--wrap,malloc -> doesn't work for 'new' gcc hooks -> doesn't work always, e.g. for uclibc there are no hooks Are there any other methods I could try?

View 2 Replies View Related

Programming :: Free PHP Code For An Online NOTEPAD For A Website?

Jun 9, 2010

I would like to have on a website a notepad ONLINE, so that my friend and me can work on a document TXT together or well we can refresh it every 5min...

well such online notepad is not free... anyone has an idea where it is possible to find the code for this. I am not good in PHP, and not informatician.

View 14 Replies View Related

Programming :: Combine 40 Different Mount Points Into One Bytes Free/used Number?

Feb 18, 2011

We have a program that catalogs to 40 different mount points. The program is fine as long as thier is free space on at least one of the 40 mount points. My boss wants me to come up with a script that will email us daily to know how much overall free space is left. I know I can do a df but I don't know how to combine the 40 mount points into a single disk used/disk free report.

The 40 mount points are /dev/mapper/areaxx, xx being 01 to 40.

View 4 Replies View Related

Programming :: Free Open Source CSV Format Parsing Software

Jun 1, 2011

Google directed me to the ones written in .Net/C# etc. Any ideas on the ones written in C/C++?

View 14 Replies View Related

Programming :: Distribute Software / Make It Free - Open Source?

Jan 15, 2010

I was wondering what would be a good, no-cost way to distribute software that I wrote? And what would be a good way to make it free/open source?

View 3 Replies View Related

Programming :: Quick Measurement Of Free System Memory From Within C Program

Jul 21, 2010

I need to monitor the amount of free physical memory on Linux from within a large C program. The sampling will occur very frequently, so the measurement cannot be performance intensive. The fact that Linux uses much of the theoretically free memory for cache and buffers means that just measuring the free pages is not sufficient. Using free + cache + buffers gives an overestimate as not all cache/buffers can be freed, but I could get a rough idea of how much generally can't and subtract that from the answer.

Possible options that I've come across so far are: Parsing /proc/meminfo - but that involves reading from file which is slow. Extracting the free, cache and buffers values from the output of the Free command - but is there a quick way to do this? Parsing the /proc/freemem file produced by the API here - but this is again reading from file. Is there a way to get that output directly? Speed is an extremely high priority, and the answer it must accurately represent the amount of memory that my program could expand into (to within a few Mb).

View 1 Replies View Related

Programming :: Bash Script To Check How Much Free Space Is Left In /var Directory

Feb 24, 2011

I'm creating a bash script to check how much free space is left in /var directory then, if it hits a certain threshold, delete certain files with numbers for extensions (e.g. fileA.1, fileA.2 fileA.3, and fileA.4, fileB.1, fileB.2 fileB.3, and fileB.4 ). Here's a snippet from my script:

[Code]...

If I use a * as a wildcard for the number extension, the script fails. Maybe regex would work here, but I'm not particularly accomplished at it. Or some other construct.

View 18 Replies View Related

Server :: Like To Understand Linux 'free' Command With Respect To Cache And Free Memory

Mar 27, 2010

Was wondering if anyone can explain briefly the relationship of "cache" and free memory in the "free" memory command.

View 2 Replies View Related

Debian Configuration :: What Default Sources.list That Has Free And Non Free Etc For Squeeze

Jun 16, 2010

During playing around sources, synaptic playing I messed up the default list. I know I should have been more careful. Anyways could someone tell me what the default the default sources.list that has free and non free etc for squueze please? I have been trying to get the default list but I cannot find it anywhere. There are alot of lists out there but nothing tagged like the "default" list.

View 6 Replies View Related

Server :: Use System Monitor Via A VNC Connection The Free Disk Space Value Is 20GB Free On The Same Volume

May 18, 2011

I've got a question on free disk space. I'm currently running CentOS 5.5 on in Xenserver virtual environment. We've had an issue with disk space. My question is as follows: - from a ssh connection i run df -h this gives the value of 90% used leaving me with 9GB. If I use system monitor via a VNC connection the free disk space value is 20GB free on the same volume. Which one is correct? I do use SNMP to monitor the same volume and should alert me when < 10% is free I know this works as I set the alert threshold to < 90% I get an alert.

View 2 Replies View Related

Fedora :: Installing Free And Non-free Repositories?

Jan 28, 2011

I've just installed Fedora 14 64bit and would like to add new repositories. I read here to do the following command (which as you can see doesn't works) :

Code:

$ su -c 'yum localinstall --nogpgcheck http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-stable.noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-stable.noarch.rpm'

[code]....

View 12 Replies View Related

Fedora :: Can't Install Rpmfusion Free And Non-free

Jan 28, 2011

I have installed F14 yesterday but i can not install rpmfusion repository, the problem is that i can not access the url [URL] so i cant download the files:

rpmfusion-free-release-stable.noarch.rpm
rpmfusion-nonfree-release-stable.noarch.rpm

View 6 Replies View Related

Ubuntu Installation :: FREE Support For FREE OS?

Jun 10, 2010

Am I asking too much for a FREE OS? Everybody spend their precious time to help others, that's very helpful.But it seems like there is no support from UBUNTU team,how could we even get through the barrier of not using Microsoft's OSes? No free lunch of course, but it seems to me some issues have never really been solved.I read lot's of people have problem with their WIFI, not just for my OLD USB wifi adapter. I don't have problem with WIFI in XP/Server.

I posted here and there, and seems like no answer, and I do not get any reply from UBUNTU support team,forgive me if I run out of google's keywords.I just need a simple answer, is my WIFI going to work in UBUNTU with a layman effort? I like linux and UBUNTU had put great effort in providing me such a great OS, but if a basic internet connection will need to spent sooo much time to setup, and it still doesn't work. IS IT WORTH to switch to UBUNTU at all

View 2 Replies View Related

General :: Add / Of 3000mb In The Remaining 20380mb Free Space It Showing An Error Message That No Free Space Is Available

Jul 25, 2010

I have 160gb laptop. i installed vista in c primary partition which is 25gb and installed ubuntu in d primary partition which is 20gb. A remainig for my data. Now i tried to install CENT OS by formatting ubuntu. I inserted CENT OS DVD and restarted and i selected to delete my /dev/sda2 which is showing 20480mb and it shown me free space. but i tried to add partion /boot of 100mb it got added. but, when i am trying to add / of 3000mb in the remaining 20380mb free space it showing an error message that no free space is available.

View 4 Replies View Related

Programming :: TBP ERROR: No Buffers Available In Free Buffers List

Jan 8, 2010

I am trying to test a Gigabit Ethernet Tattile line scan camera. I installed the driver properly set the ip of device using utility given in the driver. when i am trying to open the live view of camera using a utility given (tag_show) it gives me error in /var/log/messages TBP ERROR: No buffers available in free buffers list When i looked into the code of utility it is doing ioctl call where it is failing with errno=12.

View 4 Replies View Related

OpenSUSE :: Is It Safe To Use Skype On 11.2

Jul 4, 2010

I know that skype not in the repositories but is it ok to use?

View 9 Replies View Related

Ubuntu :: Is Running (any) As Vm Still As Safe

Jan 23, 2010

What I mean to ask if any of the things that linux users benefit from as far as viruses and spyware remain same when running a virtual linux box in virtualbox as an exampledditionally does this greatly increase the chance of passing.

View 1 Replies View Related

Ubuntu :: Is It Safe To Uninstall HAL In 10.04 And 9.10

Mar 4, 2010

can I uninstall HAL from Ubuntu 10.04? i tried it on 9.10 2 weeks ago and unfortunately the dependencies also uninstalled the entire gnome desktop and many other essential things leaving me with a bulky half broken mock arch linux. if this is safe let me know I am dying to try out Device Kit to see how fast it really is.

View 3 Replies View Related

Ubuntu :: Safe Way To Upgrade To 10.10?

Nov 30, 2010

I am using 10.04 right now and the other time i tried upgrading to 10.10 beta version or alpha version it turned out to be a complete disaster cause it just wouldnt boot into the GUI no matter what. People say it was due to my ATI driver. Now since its a stable release, I want to make this install as perfect as possible so i dont have to reformat everything like i did last time.

Should i copy my whole filesystem into a external drive? In the event it doesnt work , i can just replace the files with the files on the external drive rite?

View 3 Replies View Related

Ubuntu :: Safe To Run Apache?

Feb 5, 2011

I'd like to install apache so I can tinker around with php a bit. I read a thread on how to set everything up, and it ended with a chap mentioning that it's important to take security measures while running apache. I haven't "gone out of my way" to make my Ubuntu install any more secure than it comes out-of-the-box. I keep my system updated via Update Manager's automatic updates, but that's it.

So my question is, am I ok to go ahead and plod through some php tutorials using apache to do the server-side stuff? what I would do to keep things safe if I were using a Windows machine?

View 1 Replies View Related

Security :: How To Keep Safe PC Using Iptables

Dec 5, 2010

I am using Fedora on my desktop pc. I want to know how can i protact my PC from outside world. What firewall policy should i implement in iptables to keep it more secure.

View 5 Replies View Related

Software :: Safe To Delete /cgi-bin?

Jun 2, 2009

It is safe to delete /cgi-bin? Will it affect when we serving via the browser?

View 5 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved