Search Results - CodeGuru Forums
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com

Search:

Type: Posts; User: Paul McKenzie

Page 1 of 80 1 2 3 4

Search: Search took 0.37 seconds.

  1. Re: STL functions shows a segmentation fault.

    If a static library is built with _SECURE_SCL=0, the all libraries that link to it that use STL must be built with the same setting.

    As to your code "working" on OS and not another machine --...
  2. Re: A question regarding throwing an exception

    It isn't just a "good practice". You cannot allow exceptions to leave a destructor, period. Therefore you have no choice but to catch anything before the destructor completes.
  3. Re: Can two functions in same DLL be called by two threads?

    How are you suspending the thread? If you're using SuspendThread, that shouldn't be used for synchronization.

    http://msdn.microsoft.com/en-us/library/windows/desktop/ms686345%28v=vs.85%29.aspx
    ...
  4. Re: Developing Unmanaged aplications in VS2013 to Work Just Like VC6 Did

    Choose the "Multi-Thread" version of the runtime library in the Project Settings instead of the "Multi-threaded DLL" version. (Properties -> C/C++ -> Code Generation -> Runtime Library).

    Also,...
  5. Re: string::pop_back: Build error in DevC++

    DevC++ is not a compiler, it is an IDE. The compiler that comes with DevC++ is an old version of g++ that does not support string::pop_back. So the solution is to get a more modern compiler (g++...
  6. Replies
    5
    Views
    2,154

    Re: Why I cannot open tiff file?

    Press Retry, look at the call stack, and inspect which functions were called that led up to the error. Since libTiff has full source code, you can easily see what is being done and the cause for the...
  7. Replies
    5
    Views
    7,076

    Re: what's wrong with this program

    What is
    sizeof(myarray) in that line of code? It is sizeof(int) * 10, which is probably 40 bytes (assuming int's are 4 bytes). Then this:

    What is
    sizeof(myarray) in that code? it is...
  8. Re: A question regarding forward slash and back slash

    A forward slash can be used in any standard C++ or C file I/O function as the directory separator.

    For specific Windows API functions, then you must be careful as to the direction of the...
  9. Re: About returning QSharedPointer or raw pointer

    1) I don't know what your question is. You mention QSharedPointer (I guess it is similar to std::shared_ptr) and a raw pointer, but no real question.

    2) You can't stop the user from doing stupid...
  10. Replies
    2
    Views
    410

    Re: std::map, insert() issue

    Maybe because the key type and mapped types could go through a silent conversion, given you the other two argument constructor being called (which could lead to hard to find bugs even though the code...
  11. Replies
    30
    Views
    2,143

    Re: [RESOLVED] Displaying a jpeg image

    Those people do not know what they're talking about.

    Even if you don't do any GUI or MFC, C++ by itself is not an easy language, and is definitely not a "cut and paste" language.

    Regards,
    ...
  12. Re: New to C++ need help with assignment.

    So what is the question that you have? Just posting the assignment, code, and asking for "hints" doesn't tell us exactly what you are having problems with.

    Regards,

    Paul McKenzie
  13. Replies
    1
    Views
    493

    Re: boost filesystem exception problem

    Yet you only assumed that the only exception thrown are ones that boost knows about.

    First, there is a difference between C++ exceptions, and the Microsoft OS structured exceptions. For example,...
  14. Re: Program runs ONLY if debugger is attached

    It doesn't matter what tool built the DLL or how old the DLL happens to be. You can run DLL's created 15+ years ago with the latest Visual Studio if the DLL's follow certain guidelines.

    If the...
  15. Re: 64 bit compatible library for UUID generator

    1) What version of g++ is it?

    2) Why are you not using the standard library that comes with the compiler? Why are you using STLPort?

    What I'm saying is that STLPort in this day and age is...
  16. Re: 64 bit compatible library for UUID generator

    What compiler are you using where you need stlport?

    Regards,

    Paul McKenzie
  17. Replies
    12
    Views
    1,159

    Re: Blackjack Game

    Then what is your specific question? You didn't post one. So the only thing to assume is that you want us to debug the program. You didn't state "I'm passing a variable x and it changes for some...
  18. Replies
    12
    Views
    1,159

    Re: Blackjack Game

    Did you write the program? If so, then you should be responsible for debugging your own programs. What debugging have you done so far?

    Regards,

    Paul McKenzie
  19. Replies
    11
    Views
    1,546

    Re: problem with arrays in WinApi

    It is an error because it is not ANSI C++ code.

    The code you were attempting is the Microsoft extension of C++ geared toward .NET development. C++/CLI or Managed C++ is what you were using,...
  20. Replies
    5
    Views
    608

    Re: Reading Jpeg pixels and change it

    Just one thing -- manipulating a JPEG file is much more complex than the code you're showing.

    Scroll to the Syntax and Structure section here:
    http://en.wikipedia.org/wiki/JPEG

    Regards,
    ...
  21. Replies
    18
    Views
    1,381

    Re: Homework help: is this a good design?

    Personally I wouldn't return references in your class. Just return the data.

    The reason is that first, the data in your class represent "simple" things -- a salary, a name, etc. The data isn't a...
  22. Replies
    18
    Views
    1,381

    Re: Homework help: is this a good design?

    //Employee dtor def;
    virtual Employee::~Employee()
    {
    // if(data) no need for this
    delete data;
    }
    There is no need to check if data is not null to delete it. It is perfectly safe to...
  23. Replies
    4
    Views
    560

    Re: Popping from STL Containers

    That code is not wrong. What *is* wrong is what you're doing with these pointers. If you corrupted memory in any way between the time you created those objects and the time you destroy those...
  24. Re: need C++ programming code in visual studio

    Actually, my technique is to use variables like llll, lllll, llllll (all the letter l), calculations that seemed tricky but were really easy, throw in some ASCII characters that serve as loop...
  25. Re: need C++ programming code in visual studio

    Funny.

    I usually reserve the obfuscated answers for those new posters that demand an answer to their homework problem. I don't know if I can dig it up again from the CodeGuru archives, but the...
Results 1 to 25 of 2000
Page 1 of 80 1 2 3 4


Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center