Search Results

Search found 13616 results on 545 pages for 'rights management'.

Page 161/545 | < Previous Page | 157 158 159 160 161 162 163 164 165 166 167 168  | Next Page >

  • Garbage collection - manually wiping EVERYTHING!

    - by Glycerine
    I have been building a game for a while (nearly done) - But the game needs a replay button and its a big task. I know the GC is dreadful in flash, but I wanted to know if there is a way to wipe EVERYTHING as if the flash app has just begun. Clearing memory, game data - I haven't to worry about game loading as its not really heavy on data. Everything pretty much lives in a DataModel - but I fear if I just clear the all variables, I'll have pockets of orphaned memory. Any forwarding idea would be great. cheers guys.

    Read the article

  • Why can't I reclaim my dynamically allocated memory using the "delete" keyword?

    - by synaptik
    I have the following class: class Patient { public: Patient(int x); ~Patient(); private: int* RP; }; Patient::Patient(int x) { RP = new int [x]; } Patient::~Patient() { delete [] RP; } I create an instance of this class on the stack as follows: void f() { Patient p(10); } Now, when f() returns, I get a "double free or corruption" error, which signals to me that something is attempted to be deleted more than once. But I don't understand why that would be so. The space for the array is created on the heap, and just because the function from inside which the space was allocated returns, I wouldn't expect the space to be reclaimed. I thought that if I allocate space on the heap (using the new keyword), then the only way to reclaim that space is to use the delete keyword. Help! :)

    Read the article

  • Should you restrict developers internet access?

    - by Craig HB
    Our (small to medium-sized) company is going to start enforcing an internet policy which everyone, including the team of 4 senior developers, will be subject to. Amongst other things, this means that developers will not be able to access: web based e-mail (Hotmail, Yahoo, Googlemail) instant messaging accounts (MSN Messenger) social networking sites (Facebook) streaming media (internet radio) At the moment, we don't have any restrictions on our internet use, so I really want to find out what the effect on the team will be. Please let me know your thoughts. What effect do you think this will have on the team (positive or negative).

    Read the article

  • Memory limit for running external executables within Asp.net

    - by itsbalur
    I am using WkhtmltoPdf in my C# web application running in .NET 4.0 to generate PDFs from HTML files. In general everything works fine except when the size of the HTML file is below 250KB. Once the HTML file size increases beyond that, the process which runs the wkhtmltopdf.exe gives an exception as below. On the Task Manager, I have seen that the Memory value for the wkhtmltopdf.exe process does not increase beyond a value of 40,096 K, which I believe is the reason why the process is abandoned in between. How can we configure such that the memory limit for external exes can be increased? Is there any other way of solving this issue? More info: When I run the conversion from the command line directly, the PDF is generated fine. So, its unlikely to be a problem with WkhtmlToPdf. The error is from localhost. I have tried the same on the DEV server, with the same result. Exception: > [Exception: Loading pages (1/6) [> > ] 0% [======> ] > 10% [======> ] 11% > [=======> ] 13% > [=========> ] 15% > [==========> ] 18% > [============> ] 20% > [=============> ] 22% > [==============> ] 24% > [===============> ] 26% > [=================> ] 29% > [==================> ] 31% > [===================> ] 33% > [=====================> ] 35% > [======================> ] 37% > [========================> ] 40% > [=========================> ] 42% > [==========================> ] 44% > [============================> ] 47% > [=============================> ] 49% > [==============================> ] 51% > [============================================================] 100% > Counting pages (2/6) > [============================================================] Object > 1 of 1 Resolving links (4/6) > [============================================================] Object > 1 of 1 Loading headers and footers (5/6) > Printing pages (6/6) [> > ] Preparing [=> > ] Page 1 of 49 [==> > ] Page 2 of 49 [===> > ] Page 3 of 49 [====> > ] Page 4 of 49 [======> > ] Page 5 of 49 [=======> > ] Page 6 of 49 [========> > ] Page 7 of 49 [=========> > ] Page 8 of 49 [==========> > ] Page 9 of 49 [============> > ] Page 10 of 49 [=============> > ] Page 11 of 49 [==============> > ] Page 12 of 49 [===============> > ] Page 13 of 49 [================> > ] Page 14 of 49 [==================> > ] Page 15 of 49 [===================> > ] Page 16 of 49 [====================> > ] Page 17 of 49 [=====================> > ] Page 18 of 49 [======================> > ] Page 19 of 49 [========================> > ] Page 20 of 49 [=========================> > ] Page 21 of 49 [==========================> > ] Page 22 of 49 [===========================> > ] Page 23 of 49 [============================> > ] Page 24 of 49 [==============================> > ] Page 25 of 49 [===============================> > ] Page 26 of 49 [=================================> > ] Page 27 of 49 [==================================> > ] Code that I use: var fileName = " - "; var wkhtmlDir = ConfigurationManager.AppSettings[Constants.AppSettings.ExportToPdfExecutablePath]; var wkhtml = ConfigurationManager.AppSettings[Constants.AppSettings.ExportToPdfExecutablePath] + "\\wkhtmltopdf.exe"; var p = new Process(); string switches = ""; switches += "--print-media-type "; switches += "--margin-top 10mm --margin-bottom 10mm --margin-right 5mm --margin-left 5mm "; switches += "--page-size A4 "; switches += "--disable-smart-shrinking "; var startInfo = new ProcessStartInfo { CreateNoWindow = true, FileName = wkhtml, Arguments = switches + " " + url + " " + fileName, UseShellExecute = false, RedirectStandardOutput = true, RedirectStandardError = true, RedirectStandardInput=true, WorkingDirectory=wkhtmlDir }; p.StartInfo = startInfo; p.Start();

    Read the article

  • UIWebView in multithread ViewController

    - by Tao
    I have a UIWebView in a viewcontroller, which has two methods as below. The question is if I pop out(tap back on navigation bar) this controller before the second thread is done, the app will crash after [super dealloc], because "Tried to obtain the web lock from a thread other than the main thread or the web thread. This may be a result of calling to UIKit from a secondary thread.". Any help would be really appreciated. -(void)viewDidAppear:(BOOL)animated { [super viewWillAppear:animated]; NSInvocationOperation *operation = [[NSInvocationOperation alloc] initWithTarget:self selector:@selector(load) object:nil]; [operationQueue addOperation:operation]; [operation release]; } -(void)load { [NSThread sleepForTimeInterval:5]; [self performSelectorOnMainThread:@selector(done) withObject:nil waitUntilDone:NO]; }

    Read the article

  • What do you do when your boss doesn't care about code quality?

    - by Chad Johnson
    My boss (a proprietor) is a developer like me. He comes, however, from a C background and severely lacks knowledge of the benefits of proper object-oriented design. That, or he simply ignores them. So my co-worker developed this feature prototype in a week, and it's not release-ready--at least not from a good code standpoint. It works; it does the job--but it'sa freaking prototype. It's totally not scalable. My boss wants to wow clients and "just get the feature out." I understand that. But, we could take two weeks and finish this shit up, or we could take three and finish this shit up AND do it so that it's scalable. I just KNOW we are going to want to add onto this feature in the coming months, and then, a customer is going to "need it in a week," and so even though we've agreed to refactor when we want to add onto the feature, IT WILL NEVER HAPPEN! This ALWAYS happens. I'm the code quality assurance guy, but my boss seems to see me as a radical and thinks I just waste time, whereas I actually am trying to follow good, known solid design patterns. He just wants his stinking feature though, and he doesn't want to spend the time or money to do things well. He pretty much listens to what I have to say, and then he ultimately just makes the decision to take the shortest path (which cuts corners a lot). I often develop large, important features for our software. THOSE THINGS TAKE TIME! They're not happy with the time it's taken with past projects, though, but the features I've put in all work really damn well and are very scalable. How do you all deal with this kind of situation?

    Read the article

  • How to react when the client's response is negative on delivery?

    - by ZiG
    I am a junior programmer. Since my supervisor told me to sit in with the client, I joined. I saw the unsatisfied face of the client despite the successful (from my programmer's perspective) delivery of the project! Client: You could have included this! Us: Was not in the specification! Client: Common Sense! As a programmer, how do you respond in this situation?

    Read the article

  • Wiki for requirements engineering

    - by Shanon
    Hi, I'm looking to to build a wiki based tool the helps/aides in the requirements engineering process. More specifically I am hoping to end up with a tool that helps inexperienced users easily create and design requirements documents on a wiki platform. I was wondering if there exist any wiki/wiki platforms that either already exist or are easily extendible or would be worth looking at that for this purpose. For instance some of the features I was hoping to add would be to add structure to a document so that information is filled out in a standardised manner. Another idea I was looking at was to somehow create relationships between different types of documents (for example- a goal diagram gets evolves/ helps in the development of the class diagram). So far I have come across FOSwiki which claims to to fully customisalble...but I'm not sure what it means and what I can really do with that. Any input on FOSwiki is also highly appreciated.

    Read the article

  • Writing efficient open source product summary and promoting project

    - by galets
    I've been working on an open source project on sourceforge a few months ago. One thing I noticed is that a well written summary could make a huge difference for the product. I literally saw traffic going to almost nothing when I made a poor change to project summary. One more thing I noticed is that not only summary has to be appealing, but also take into consideration some technical aspects, such as (for example): contain all the necessary keywords for it to be searchable and produce the best match for a hypothetical search potential user will make in order to find it. Here comes the question now: can you share your tips and tricks for writing an efficient product summary, and otherwise promoting your project, whether it's on sourceforge or somewhere else?

    Read the article

  • Received memory warning and app crashes - iphone

    - by Anand Gautam
    I am creating an app using ARC but my app is crashing due to Received memory warning. The App is working fine in simulator. But in case of iphone device, If i run the app for few minutes then on doing anything, the app crashes straightaway. I have checked my app by xcode instrument. My app folder size is 6 MB but all memory allocation is showing 63 MB on xcode instrument. Because of this reason, presentViewController-Animated-Completion is getting slow during navigation. Does anyone have any solution why this is happening?

    Read the article

  • Conceptual question about NSAutoreleasePools

    - by ryyst
    In my Cocoa program, wouldn't a really simple way of dealing with autoreleased objects be to just create a timer object inside the app delegate that calls the following method e.g. every 10 seconds: if (pool) { // Release & drain the current pool to free the memory. [pool release]; } // Create a new pool. pool = [[NSAutoreleasePool alloc] init]; The only problems I can imagine are: 1) If the above code runs in a separate thread, an object might get autoreleased between the release call to the old pool and the creation of the new pool - that seems highly unlikely though. 2) It's obviously not that efficient, because the pool might get released if there's nothing in it. Likewise, in the 10 second gap, many many objects might be autoreleased, causing the pool to grow a lot. Still, the above solution seems pretty suitable to small and simple projects. Why doesn't anybody use it? What's the best practice of using NSAutoreleasePools?

    Read the article

  • Strange menu issue

    - by Ber53rker
    Just started out with Orchard and trying to just make pages and menus. I'm running into an issue where on my home page my menu shows: Home, Fruit, Vegetable, Carrot. I want it to show just Home, Fruit, Vegetable and when I click the respective item it adds the proper tabs. It DOES do it with Banana. ie: When I click Fruit, it shows Banana in the menu. But it always shows Carrot for some reason! I have the following setup. Navigation -Main Menu --Home --Fruit --Vegetable -Fruit Menu --Banana -Vegetable Menu --Carrot Widgits > Navigation > Main Menu, Fruit Menu, Vegetable Menu (Fruit and Vegetable Menus are in their own respective layers.) Path Examples: /Fruit, /Fruit/Banana, /Vegetable, /Vegetable/Carrot Thanks in advance.

    Read the article

  • Deploying Multiple Environments in Spring-MVC

    - by jboyd
    Currently all web apps are deployed using seperate config files: <!-- <import bean.... production/> --> <import bean... development/> This has disadvantages, even if you only need to swap out one config file, that I'm sure everyone is familiar with (wondering what just deployed without searching through XML is one of them) I want to add Logging to my application that basically says 'RUNNING IN PRODUCTION MODE', with a description of the services deployed and what mode they are working in. RUNNING IN PRODUCTION MODE Client Service - Production Messaging Service - Local and so on... Is this possible in Spring using a conventional deployment (putting a war on a server)? What other things do people do to manage deployments and software configurations? If not, what other ways could you achieve something similar?

    Read the article

  • Remove pointer object whose reference is mantained in three different lists

    - by brainydexter
    I am not sure how to approach this problem: 'Player' class mantains a list of Bullet* objects: class Player { protected: std::list< Bullet* > m_pBullet_list; } When the player fires a Bullet, it is added to this list. Also, inside the constructor of bullet, a reference of the same object is updated in CollisionMgr, where CollisionMgr also mantains a list of Bullet*. Bullet::Bullet(GameGL*a_pGameGL, Player*a_pPlayer) : GameObject( a_pGameGL ) { m_pPlayer = a_pPlayer; m_pGameGL->GetCollisionMgr()->AddBullet(this); } class CollisionMgr { void AddBullet(Bullet* a_pBullet); protected: std::list< Bullet*> m_BulletPList; } In CollisionMgr.Update(); based on some conditions, I populate class Cell which again contain a list of Bullet*. Finally, certain conditions qualify a Bullet to be deleted. Now, these conditions are tested upon while iterating through a Cell's list. So, if I have to delete the Bullet object, from all these places, how should I do it so that there are no more dangling references to it? std::list< Bullet*>::iterator bullet_it; for( bullet_it = (a_pCell->m_BulletPList).begin(); bullet_it != (a_pCell->m_BulletPList).end(); bullet_it++) { bool l_Bullet_trash = false; Bullet* bullet1 = *bullet_it; // conditions would set this to true if ( l_Bullet_Trash ) // TrashBullet( bullet1 ); continue; } Also, I was reading about list::remove, and it mentions that it calls the destructor of the object we are trying to delete. Given this info, if I delete from one list, the object does not exist, but the list would still contain a reference to it..How do I handle all these problems ? Can someone please help me here ? Thanks PS: If you want me to post more code or provide explanation, please do let me know.

    Read the article

  • what do you do while code is compiling

    - by Jacob
    I'm looking for the best idea for what to do while code is compiling or tests are running. Typically around 5 minutes of thumb twiddling. Only so many cups of coffee can be made and drunk in a day, and I don't want to be seen always in the kitchen or bothering other people.

    Read the article

  • Deallocation doesn't free mem. in Windows/C++ Application

    - by Paul Baumer
    Hi, My Windows/C++ application allocates ~1Gb of data in memory with the new operator and processes this data. The data is deleted after processing. I noticed that if I run the processing again without exiting the application, the second call to "new" operator to allocate ~1gb of data fails. I would expect Windows to deliver back the memory again. Could this be managed in a better way with some other win32 calls etc. ? Thanks, Paul

    Read the article

  • Custom Memory Allocator for STL map

    - by Prasoon Tiwari
    This question is about construction of instances of custom allocator during insertion into a std::map. Here is a custom allocator for std::map<int,int> along with a small program that uses it: #include <stddef.h> #include <stdio.h> #include <map> #include <typeinfo> class MyPool { public: void * GetNext() { return malloc(24); } void Free(void *ptr) { free(ptr); } }; template<typename T> class MyPoolAlloc { public: static MyPool *pMyPool; typedef size_t size_type; typedef ptrdiff_t difference_type; typedef T* pointer; typedef const T* const_pointer; typedef T& reference; typedef const T& const_reference; typedef T value_type; template<typename X> struct rebind { typedef MyPoolAlloc<X> other; }; MyPoolAlloc() throw() { printf("-------Alloc--CONSTRUCTOR--------%08x %32s\n", this, typeid(T).name()); } MyPoolAlloc(const MyPoolAlloc&) throw() { printf(" Copy Constructor ---------------%08x %32s\n", this, typeid(T).name()); } template<typename X> MyPoolAlloc(const MyPoolAlloc<X>&) throw() { printf(" Construct T Alloc from X Alloc--%08x %32s %32s\n", this, typeid(T).name(), typeid(X).name()); } ~MyPoolAlloc() throw() { printf(" Destructor ---------------------%08x %32s\n", this, typeid(T).name()); }; pointer address(reference __x) const { return &__x; } const_pointer address(const_reference __x) const { return &__x; } pointer allocate(size_type __n, const void * hint = 0) { if (__n != 1) perror("MyPoolAlloc::allocate: __n is not 1.\n"); if (NULL == pMyPool) { pMyPool = new MyPool(); printf("======>Creating a new pool object.\n"); } return reinterpret_cast<T*>(pMyPool->GetNext()); } //__p is not permitted to be a null pointer void deallocate(pointer __p, size_type __n) { pMyPool->Free(reinterpret_cast<void *>(__p)); } size_type max_size() const throw() { return size_t(-1) / sizeof(T); } void construct(pointer __p, const T& __val) { printf("+++++++ %08x %s.\n", __p, typeid(T).name()); ::new(__p) T(__val); } void destroy(pointer __p) { printf("-+-+-+- %08x.\n", __p); __p->~T(); } }; template<typename T> inline bool operator==(const MyPoolAlloc<T>&, const MyPoolAlloc<T>&) { return true; } template<typename T> inline bool operator!=(const MyPoolAlloc<T>&, const MyPoolAlloc<T>&) { return false; } template<typename T> MyPool* MyPoolAlloc<T>::pMyPool = NULL; int main(int argc, char *argv[]) { std::map<int, int, std::less<int>, MyPoolAlloc<std::pair<const int,int> > > m; //random insertions in the map m.insert(std::pair<int,int>(1,2)); m[5] = 7; m[8] = 11; printf("======>End of map insertions.\n"); return 0; } Here is the output of this program: -------Alloc--CONSTRUCTOR--------bffcdaa6 St4pairIKiiE Construct T Alloc from X Alloc--bffcda77 St13_Rb_tree_nodeISt4pairIKiiEE St4pairIKiiE Copy Constructor ---------------bffcdad8 St13_Rb_tree_nodeISt4pairIKiiEE Destructor ---------------------bffcda77 St13_Rb_tree_nodeISt4pairIKiiEE Destructor ---------------------bffcdaa6 St4pairIKiiE ======Creating a new pool object. Construct T Alloc from X Alloc--bffcd9df St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE +++++++ 0985d028 St4pairIKiiE. Destructor ---------------------bffcd9df St4pairIKiiE Construct T Alloc from X Alloc--bffcd95f St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE +++++++ 0985d048 St4pairIKiiE. Destructor ---------------------bffcd95f St4pairIKiiE Construct T Alloc from X Alloc--bffcd95f St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE +++++++ 0985d068 St4pairIKiiE. Destructor ---------------------bffcd95f St4pairIKiiE ======End of map insertions. Construct T Alloc from X Alloc--bffcda23 St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE -+-+-+- 0985d068. Destructor ---------------------bffcda23 St4pairIKiiE Construct T Alloc from X Alloc--bffcda43 St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE -+-+-+- 0985d048. Destructor ---------------------bffcda43 St4pairIKiiE Construct T Alloc from X Alloc--bffcda43 St4pairIKiiE St13_Rb_tree_nodeISt4pairIKiiEE -+-+-+- 0985d028. Destructor ---------------------bffcda43 St4pairIKiiE Destructor ---------------------bffcdad8 St13_Rb_tree_nodeISt4pairIKiiEE Last two columns of the output show that an allocator for std::pair<const int, int> is constructed everytime there is a insertion into the map. Why is this necessary? Is there a way to suppress this? Thanks! Edit: This code tested on x86 machine with g++ version 4.1.2. If you wish to run it on a 64-bit machine, you'll have to change at least the line return malloc(24). Changing to return malloc(48) should work.

    Read the article

  • How to explain to a client that you've gone over-budget and you'll need more money/time to deliver w

    - by General Tapioca
    My situation is that I have agreed on a per-project proposal with the client. The proposal is vague, but still names functionality in a way that can be argued as to whether it's included or not, while leaving some room for interpretation. I originally pressed as much as I could to get a per-month contract, arguing that the project is mostly non-predictable, but the client refused. Being a small company, I had to fold and signed a contract on an estimate based on my group's estimations. At this point we have reached completion on about 85% of the features (we think) but we ran out of budget. We have been working for almost two years with this client in previous contracts, and we have delivered a good product that they are happy with, so we have a good standing relationship. More info: -There has been a bit of scope-creep, but I don't think enough for me to hide behind that argument -We've been delivering partial releases about monthly. -We don't have systematic user-testing in place.

    Read the article

  • What arguments to use to explain why a SQL DB is far better then a flat file

    - by jamone
    The higher ups in my company were told by good friends that flat files are the way to go, and we should switch from MS SQL server to them for everything we do. We have over 300 servers and hundreds of different databases. From just the few I'm involved with we have 10 billion records in quite a few of them with upwards of 100k new records a day and who knows how many updates... Me and a couple others need to come up with a response saying why we shouldn't do this. Most of our stuff is ASP.NET with some legacy ASP. We thought that making a simple console app that tests/times the same interactions between a flat file (stored on the network) and SQL over the network doing large inserts, searches, updates etc along with things like network disconnects randomly. This would show them how bad flat files can be espically when you are dealing with millions of records. What things should I use in my response? What should I do with my demo code to illustrate this? My sort list so far: Security Concurent access Performance with large ammounts of data Ammount of time to do such a massive rewrite/switch Lack of transactions PITA to map relational data to flat files I fear that this will be a great post on the Daily WTF someday if I can't stop it now.

    Read the article

  • Memory Leak from Foundation & CFNetwork Library

    - by Lakshmie
    I am using instruments to resolve memory leak issues for an app in iPhone. I just wanted to know if I have to resolve the leaks coming from Foundation and CFNetwork Libraries. Specifically, the leaks are from: 1. NSCFString 2. NSConcreteData 3. General Block-3584 Since they do not directly point to the code that I have written, how should I resolve them, if I have to? Thanks.

    Read the article

  • Any sense to set obj = null(Nothing) in Dispose()?

    - by serhio
    Is there any sense to set custom object to null(Nothing in VB.NET) in the Dispose() method? Could this prevent memory leaks or it's useless?! Let's consider two examples: public class Foo : IDisposable { private Bar bar; // standard custom .NET object public Foo(Bar bar) { this.bar = bar; } public void Dispose() { bar = null; // any sense? } } public class Foo : RichTextBox { // this could be also: GDI+, TCP socket, SQl Connection, other "heavy" object private Bitmap backImage; public Foo(Bitmap backImage) { this.backImage = backImage; } protected override void Dispose(bool disposing) { if (disposing) { backImage = null; // any sense? } } }

    Read the article

  • Naive question of memory references in Operating system

    - by darkie15
    Hi All, I am learning memory references pertaining to Operating systems and don't seem to get to the crux of understanding it. For example, I am not able to visualize this scenario properly: "A 36 bit address employs both paging and segmentation. Both PTE and STE are 4 bytes each". How are they related? I can guess that this question might be too simple for many. But any help understanding the above basic concept would be appreciable. Regards, darkie15

    Read the article

< Previous Page | 157 158 159 160 161 162 163 164 165 166 167 168  | Next Page >