[LATEST] Icarus Emulator [Java, Netty, MySQL, Plugins, Camera]

Page 16 of 23 FirstFirst ... 6891011121314151617181920212223 LastLast
Results 226 to 240 of 333
  1. #226
    Developer Quackster is offline
    DeveloperRank
    Dec 2010 Join Date
    AustraliaLocation
    3,470Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by The General View Post
    @Quackster:

    Is your source code anywhere publicly available? I would love to see all the memory leaks you're creating! (No jk, just want to give some feedback)
    Source isn't available, yet.

    Quote Originally Posted by The General View Post
    Also, why Visual C++??? I mean out of everything you could've picked you pick THAT.
    I'm using Visual Studio because that was the first thing I had. Moving to CLion later if I can figure out how to fix a problem where stopping the debug doesn't actually close the process.

    There's nothing wrong with Visual Studio, so don't push your opinion on to me.

    Quote Originally Posted by The General View Post
    PS: Avoid this-> all together in C++. Except when you're having ambiousity (Or however you write it) or have to pass a pointer to a function. Its cluttering and the majority of the C++ community avoids this as much as possible. Use naming conventions.
    No.

    Quote Originally Posted by The General View Post
    Also you have atleast 2 memory leaks in your Request class.
    No. I don't. I tested this over and over again and I don't.

    Quote Originally Posted by The General View Post
    Also you read a short but return it as an int. Int is platform depended and may not always be equally sized as a short. (My suggestion don't use int at all but use long (Or even better use int<bitsize>_t eg int32_t)
    Shouldn't be a problem because I'm converting shorts to integers, not the other way around.

    Quote Originally Posted by The General View Post
    I don't think you have to cast the chars to unsigned char in readShort. (1: They keep their bit pattern anyways, 2: you already read from an char*)
    I do, otherwise the outcomes are different.

    Quote Originally Posted by The General View Post
    I wish you luck, because you will need it.
    You're the one who needs luck around here, you seem to assume that I didn't put things the way I did for a reason.
    Last edited by Quackster; 28-09-16 at 03:39 AM.

  2. #227
    [LATEST] Icarus Emulator [Java, Netty, MySQL, Plugins, Camera][LATEST] Icarus Emulator [Java, Netty, MySQL, Plugins, Camera] pel is offline
    MemberRank
    Jan 2012 Join Date
    Munich, GermanyLocation
    384Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Quackster View Post
    Don't know.



    Java > Python > C++

    3 times.
    After 3 comes 4.

  3. #228
    Developer Quackster is offline
    DeveloperRank
    Dec 2010 Join Date
    AustraliaLocation
    3,470Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by iExit View Post
    After 3 comes 4.
    Right, but this is the second time I've changed languages, third time I've started over. How is that hard to understand?

  4. #229
    [LATEST] Icarus Emulator [Java, Netty, MySQL, Plugins, Camera][LATEST] Icarus Emulator [Java, Netty, MySQL, Plugins, Camera] pel is offline
    MemberRank
    Jan 2012 Join Date
    Munich, GermanyLocation
    384Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Quackster View Post
    Right, but this is the second time I've changed languages, third time I've started over. How is that hard to understand?
    Why its hard to understand that after 3 comes 4? He wrote "... 3rd time. Whats next?" and its obvious 4.

  5. #230
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,607Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Quackster View Post
    Source isn't available, yet.



    I'm using Visual Studio because that was the first thing I had. Moving to CLion later if I can figure out how to fix a problem where stopping the debug doesn't actually close the process.

    There's nothing wrong with Visual Studio, so don't push your opinion on to me.



    No.



    No. I don't. I tested this over and over again and I don't.



    Shouldn't be a problem because I'm converting shorts to integers, not the other way around.



    I do, otherwise the outcomes are different.



    You're the one who needs luck around here, you seem to assume that I didn't put things the way I did for a reason.
    Clion and Visual C++? Goodluck with that because CLion uses CMake and visual C++ has its own buildtools.

    Memory leak 1 is in your constructor, you take a char* but you will never delete it.

    Memory leak 2 is in your read string method. You return a char* but you will never delete it. If you call new you have to delete it at some point.

    I assume you didnt run your program using Valgrind or something.

    Should upload the sources to github or send me a copy through PM. I want to help you with feedback Alex, not shoot you down.

  6. #231
    Proficient Member Boraida is offline
    MemberRank
    May 2011 Join Date
    The NetherlandsLocation
    161Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    According to @The General "Memory leak 2" return a smart pointer instead of a raw one. And maybe delete the "full_message" in the deconstructor?

    After all good luck with your C++ server! :-)

  7. #232
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,607Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Boraida View Post
    According to @The General "Memory leak 2" return a smart pointer instead of a raw one. And maybe delete the "full_message" in the deconstructor?

    After all good luck with your C++ server! :-)
    The fact that this is already in one class makes me worry what other inventive things he will eventually code...

  8. #233
    Proficient Member Boraida is offline
    MemberRank
    May 2011 Join Date
    The NetherlandsLocation
    161Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Btw checkout Boost.Asio. It's awesome and it supports cross-platform networking.
    Last edited by Boraida; 28-09-16 at 05:54 PM.

  9. #234
    Live Ocottish Sverlord Joopie is offline
    LegendRank
    Jun 2010 Join Date
    The NetherlandsLocation
    2,767Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    *tik tik tik tik* ... (when will it go boem?)


  10. #235
    Alpha Member Caustik is offline
    MemberRank
    May 2011 Join Date
    LondonLocation
    1,837Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by The General View Post


    Because the reason they picked python for it is because they can easily without too much hassle make it distributed. Something which is also possible in C++ but is a bit more difficult to implement and maintain.

    Its also the reason why a lot of these services (reddit, paypal, google) moved from Java to Python. The JMS is just slower and it was easier to move to Python.
    What..? I didn't mention C++, or Java. You need to learn basic literacy.

  11. #236
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,607Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Boraida View Post
    Btw checkout Boost.Asio. It's awesome and it supports cross-platform networking.
    Thats what I am using but I am afraid the documentation would be too complicate for him to understand.

    (If he manages to somehow install it

  12. #237
    Developer Quackster is offline
    DeveloperRank
    Dec 2010 Join Date
    AustraliaLocation
    3,470Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Joopie View Post
    *tik tik tik tik* ... (when will it go boem?)

    Fixed.

    - - - Updated - - -

    Quote Originally Posted by The General View Post
    Clion and Visual C++? Goodluck with that because CLion uses CMake and visual C++ has its own buildtools.
    Did you even read what I said? Dude.. c'mon I said I'm moving to CLion and Cgywin32 if I can figure out an issue I'm having where if I cancel the debug, the actual process isn't closed.

    Quote Originally Posted by The General View Post
    Memory leak 1 is in your constructor, you take a char* but you will never delete it.
    Actually, since that array was never created with "new" it's been automatically memory allocated, instead of being dynamically allocated (like pointers are) so when the object goes out of the scope, it will be deleted automatically.

    Quote Originally Posted by The General View Post
    Memory leak 2 is in your read string method. You return a char* but you will never delete it. If you call new you have to delete it at some point.
    Using std::string now without any "new" keyword, so once it goes out of the scope it will be automatically freed.

  13. #238
    Alpha Member Moogly is offline
    MemberRank
    Feb 2008 Join Date
    Pool LidoLocation
    2,322Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Quackster View Post
    I noticed my links were messed up, here you go fam: https://github.com/Habbotard/Icarus-Python



    If I wanted to use C++ I'll use C++, there's no "should've". Sorry.
    Oh right, thank you sir. :)

    Provided Quackster doesn't update the repo or delete the old commits assuming this current version is the very last anyone wanting to directly download the code can do so here:
    https://github.com/Habbotard/Icarus-...c358495086.zip

    Edit:

    On another note, check out D sometime:
    Home - D Programming Language

    It was started by someone who wrote C++ compilers for years, decided, screw this, C++ has too many limitations because of forced backward compatibility to C (a C++ compiler should be able to compile a C program in other words). He added in nice things like Garbage Collection (optional / modifiable), and it's fully compiled. Look into it when you get sick of C++. Go is only good for the out of the box standard libraries, D is good for OO programming, and other stuff. D is evolving nicely now that it's matured. You can install it with a Visual Studio plugin too.

  14. #239
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,607Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by Quackster View Post
    Fixed.

    Did you even read what I said? Dude.. c'mon I said I'm moving to CLion and Cgywin32 if I can figure out an issue I'm having where if I cancel the debug, the actual process isn't closed.

    Actually, since that array was never created with "new" it's been automatically memory allocated, instead of being dynamically allocated (like pointers are) so when the object goes out of the scope, it will be deleted automatically.

    Using std::string now without any "new" keyword, so once it goes out of the scope it will be automatically freed.
    You did not mention Cygwin, which is only a set of linux like tools for windows and provides a linux like API. Also Cygwin isn't really needed, MingW should suffice. (As you only need the GCC compiler).

    I don't think you've got any clue what you're doing and probably just following some tutorials on the internet....

    Also CLion uses CMake so you need that too.

  15. #240
    Developer Quackster is offline
    DeveloperRank
    Dec 2010 Join Date
    AustraliaLocation
    3,470Posts

    Re: Icarus Server (Production) - [Python, Multi-DB/MySQL]

    Quote Originally Posted by The General View Post
    You did not mention Cygwin, which is only a set of linux like tools for windows and provides a linux like API. Also Cygwin isn't really needed, MingW should suffice. (As you only need the GCC compiler).

    I don't think you've got any clue what you're doing and probably just following some tutorials on the internet....

    Also CLion uses CMake so you need that too.
    What else did you think i was going to use if I wanted to make my C++ program cross-compatible and develop it on Windows?

    No. MingW _does not_ suffice.

    You're free to think whatever you want, but you're the one who assumed that just because you can see a pointer being created, you believe it wasn't being deleted.

    I know what CLion uses and doesn't use, stop telling me this.



Advertisement