67 Solved Topics

Remove Filter
Member Avatar for
Member Avatar for ogsirus

Hi Guys I ran into a bit of a problem with some code I am writing. I am trying to store all possible combinations of a set of numbers which are current being stored in List. Problem is my code run into an out of memory exception, heres my code: …

Member Avatar for ogsirus
0
2K
Member Avatar for mike_2000_17

Hi all, I just noticed a signficant slow-down with Daniweb, not with the server, but with the site (javascript?), in particular, with the editor that jams every few seconds. So, I checked by task manager and found that one Chrome tab was taking quite a bit of resources (memory + …

Member Avatar for mike_2000_17
0
1K
Member Avatar for elouch

hi all i've been strugling with this error. could someone help me. below is the code stremail = "some@email" For Each store In outlookapp.Session.Stores strchecking = store.DisplayName outlookfolder = store.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderInbox) For Each objfolder In outlookfolder.Folders For Each obj As Object In objfolder If TypeOf (obj) Is Outlook.MailItem Then MsgBox(obj.Subject) End …

Member Avatar for elouch
0
4K
Member Avatar for Labdabeta

Hello, I was recently looking through some of my code and found what I believe to be a memory leak. It is in a function that appends two strings and I am not sure how to resolve it. Here is the function: const char *strapp(const char *str,const char *s) { …

Member Avatar for mike_2000_17
0
438
Member Avatar for MaddTechwf

I'm trying to pull the total physical memory on a machine and have it show just like it would inside My Computer Properties. I know I can use My.Computer.Info.TotalPhysicalMemory which will return it in bytes. This is where I'm getting stuck. I want to be able to divide it and …

Member Avatar for uchy69
0
1K
Member Avatar for nikolaos

Testing the following code from a book public class RunTime { public static void main(String[] args) { Runtime r = Runtime.getRuntime(); //MEMORY MANAGEMENT long mem1, mem2; Integer intmatrix[] = new Integer[1000]; System.out.println("Total memory is :" + r.totalMemory()); mem1 = r.freeMemory(); System.out.println("Initial free memory is :" + mem1); r.gc(); mem1 = …

Member Avatar for mKorbel
0
768
Member Avatar for jkon

Hello, I suspect that this is an elementary question but maybe I don’t understand how to search for it. I am a programmer, but having a small company and we can’t afford yet a system administrator, so I play this role as well with my limited practice on it. Currently …

Member Avatar for rubberman
0
441
Member Avatar for jackmaverick1

I've been working on a small API/Library and I realized that I was returning memory that wasn't going to be consistently put on the heap or stack. So my question is this: when I return an object from a function in a Library, should that object be on the heap? …

Member Avatar for mike_2000_17
0
234
Member Avatar for irtza

These are two simple programs. In first program, i used static array, while in second program i used dynamic array. Both programs do the same job i.e. initiaze the array by asking the user to enter the their test scores. The problem is: 1)i have read in many books that …

Member Avatar for vijayan121
0
4K
Member Avatar for Labdabeta

Hello, I made an arbitrary precision integer library a few weeks ago. It works well, but is bounded by `256^(8*sizeof(size_t))` because it uses a simple dynamically allocated array to do its work. I want some way to have theoretically unbounded storage. I think that file io is probably best, but …

Member Avatar for Labdabeta
0
207
Member Avatar for Aethir

# This is an advanced guess the number game. import random # The very basis of this game. import math # Used for math.ceil import time # Used to split up long portions of text. def errorDisplay(errorCode): if errorCode == '1': print('\n\n\nError ' + errorCode + ': unlockedGameModes outside of …

Member Avatar for Aethir
0
277
Member Avatar for TarkiB

Hi all! I'm trying to create a program that produces a memory leak. I have a program that looks like it works, but I was wanting to verify whether it actually is causing a memory leak, and that it's not just some other type of issue. It's in C++, which …

Member Avatar for mike_2000_17
0
372
Member Avatar for JE821

I'm not sure if I'm freeing the memory correctly. I have the following struct and I'm trying to free the pointer in it. typedef struct RECORD { char* name; int score; }RECORD; In my main function I have an array of this struct, therefore I'm using a loop to free …

Member Avatar for JE821
0
272
Member Avatar for 9tontruck

Hi, I am implementing an applicaiton which uses CPU but having a problem about allocating in GPU memory. Above all, my work environment is Windows 7 Visual Studio 2010 NVIDIA Quadro NVS 290 (256MB) When I run a piece of CUDA code: cudaMemGetInfo(&freeMem, &totalMem); I get 256MB of total memory …

Member Avatar for 9tontruck
0
378
Member Avatar for James19142

I just started using Qt5 and now i'm getting an error which seems to be generated near the end of compiling saying this: cc1plus.exe: out of memory allocating 408 bytes. I compiled this same exact code in Qt 4.8.1 without any problems multiple times. I have no way of getting …

0
127
Member Avatar for halo3rlz

hi, I made a new partition to install vista because i wanted to make sure i would have all the files i needed before i normally would've cleaned the original partition and installed it there. I plan to keep the second partition and i would like to move memory from …

Member Avatar for oalee
0
275
Member Avatar for phfilly

Hi I have trouble with implementing a dynamic two dimensional pointer array on allocating memory for it. I tried it this way but not sure if it's correct. The array should contain pointers to heap allocated **Integer** objects const int size = 10; Integer *** twoD; twoD = new Integer**(); …

Member Avatar for Ancient Dragon
0
320
Member Avatar for taylor.mitchell.353

I am making a project using hashtables. I have to use a linked list to handle duplicate hashcodes. The Objects that I am turning into hash tables are State objects with just a String name. I have debugged and tested my entire project and cannot figure out why it is …

Member Avatar for taylor.mitchell.353
0
691
Member Avatar for kedxu

I'm probably doing this wrong, because there has to be a way to do this. Here is my current code: import javax.sound.sampled.*; public class soundHandler{ soundHandler() { } public void newSound(String sound) { new soundThread(sound).start(); } } class soundThread extends Thread { String soundName; Clip clip = null; soundThread(String i_soundName) …

Member Avatar for ~s.o.s~
0
366
Member Avatar for mmcdonald

Would you say its time to increase the RAM on this lil machine or is it okay? Could you please explain this output? free -m -s 5 total used free shared buffers cached Mem: 496 439 57 0 20 250 -/+ buffers/cache: 167 328 Swap: 511 5 506 Thanks, M

Member Avatar for mmcdonald
0
161
Member Avatar for grh1107

currently I'm rewriting old euler solutions into classes so i can store them in a library. I wrote a program that digitizes a number so it can check to see if it a pallindrome, The base class digitize dynamically allocates memory for the size of a number and stores each …

Member Avatar for mike_2000_17
0
247
Member Avatar for rahim_fayaz

Hi I am getting this error when running a very similar code like the below. I have memory problem,but i dont know how can solve it. please help. Thanks in advance. /////////////////////////////////////////// ~~~~~~~ERROR~~~~~~~~ terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc Aborted /////////////////////////////////////////// ~~~~~~~~Code~~~~~~~~~ int main(){ /** Declare …

Member Avatar for rahim_fayaz
0
135
Member Avatar for niyasc

Following is the one of code written by me for shared memory. Problem is that program donot come outside from marked loop and read numbers infinitely. "common.h" [CODE] struct common { int a[10],b[10],c[10],flag; }; [/CODE] p1.c [CODE] #include<stdio.h> #include<unistd.h> #include<stdlib.h> #include<sys/shm.h> #include"common.h" int main() { int running=1; void *shm=(void *)0; …

Member Avatar for niyasc
0
209
Member Avatar for Labdabeta

I have a program that dynamically allocates an array and uses it. The thing is that under certain situations this array will get infinitely long. As such I would like to know if/when the array has gotten too long and then start saving it to a file (where length will …

Member Avatar for Labdabeta
0
170
Member Avatar for desup

Hi, I am new to java and I need to work with arrays. I have found some tutorials, but everywhere was something like [CODE] int[] anArray; // allocates memory for 10 integers anArray = new int[10]; [/CODE] But what if I dont know how long the array will be? When …

Member Avatar for desup
0
147
Member Avatar for Connavar3

Hi everyone! I have written a server client that receives information, does a database transaction and then sends the result back to the client. My client has requested that they be able to view what was received and what was sent in real time. I have used a JTextArea. The …

Member Avatar for Connavar3
0
405
Member Avatar for LateNightCoder

In my program I read in a text file an decrypt the text from an array. once decrypted i then have to do through it again and search for every tenth array member and show their memory location. The code so far: [CODE] int main( ) { int* pCrypted = …

Member Avatar for LateNightCoder
0
287
Member Avatar for Dante2

Ok, I am walking my way through an instructional php book and basically going over the basics again. After I finished doing the script the way the book said to do it, I kept getting a header error saying that the headers have already been submitted. The book had my …

Member Avatar for Dante2
0
186
Member Avatar for vinithktp

Hi, I am facing OutOfMemory exception in Java, Kindly help me to resolve this issue, really appreciate your help [U][B]ERROR: [/B][/U]java.lang.OutOfMemoryError: Java heap space [B][U]CODE:[/U][/B] [CODE] public Blob getBlob(String databaseInstance, InputStream inputStream) throws SQLException, Exception { applog.info("Entering getBlob"); InputStream stream = null; applog.info("inputStream : " + inputStream); stream = inputStream; …

Member Avatar for vinithktp
0
895
Member Avatar for 54uydf

Hi, I'm getting this error: Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 576 bytes) in 'path' on line 207 what I'm doing is getting an excel file with about 8000+ rows and trying to move them into a table in my DB. a FOR loop …

Member Avatar for digital-ether
0
3K

The End.