wolkykim / qlibc

qLibc is a simple and yet powerful C library providing generic data structures and algorithms.

Home Page:http://wolkykim.github.io/qlibc

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Let us know if you're using qlibc! Also don't forget to give a Star to this project~

wolkykim opened this issue · comments

It's always my great pleasure to know how it gets used.
Please leave your comment if you're using qlibc.
And any change, giving a Star to the project helps!
Many thanks.

Hi. I'm using qLibc because of qhashtbl_t is been very useful for me.
However, I don't know why when I nest a qhashtbl_t in a qhashtbl_t, Valgrind complains that there're blocks that are definitely lost.
I think I can't free none qhashtbl_t until the program ends, because when I put a qhashtbl_t in another one, not all the qhashtbl_t child is copied to qhashtbl_t parent. It's ok?
Regards.

Sorry, I'm little fuzzy on what you said.
So do you mean the case when you put hashtbl objects into a parent hash table like tbl->put(tbl, keyname, another_tbl); In that case, tbl->free() won't release another_tbl, in this case, you need to iterate on the tbl to release another_tbl and finally release tbl itself.
Let me know if I misunderstand what you meant.

PS: if this is more of question or bug report, could you please open a separate issue for better handling? Thanks

Thank you for your quick reply! That is exactly what I'd asked.
I use (according to 2.1.0 version):

qhashtbl_t *tbl = qhashtbl(1000);
qhashtbl_t *tbl_tipo = qhashtbl(1000);

I fill "tbl_tipo" with some values and finally I put "tbl_tipo" in "tbl":

tbl->put(tbl, key_string, tbl_tipo, sizeof(qhashtbl_t));

I'm going to test your solution. In case of a problem I'll write a bug report.
Regards.

Well. I suppose I don't have to pay attention to those errors, because I need the parent hash (and his content) during the all runtime and Valgrind complains about them when the program ends.

I see. Yes tbl->free() will only free the pointer to tbl_tipo. In order to make the valgrind happy,
you'll need to free it in this way:

LOOP subtbl := tbl->next()
subtbl->free()
ENDLOOP
tbl->free()

Hello, how can i send a POST using qhttp_client?
I tried qhttp_client->cmd, but it doesn't work with web services.

Thanks in advance for your help

Luis JImenez

Please cut an issue ticket for any questions and bug reports.

I'm not familiar with Licenses.

  1. Can I use your code in my programs?
  2. If yes, can I push your code to remote repos (github, sourceforge, googlecode)?
  3. What if I use parts of your code in my files?
  4. What if I make changes in your files (probably devastating)?

I've already started using qlibc. I've got qunit.h file, and I'm trying first assertions.

@mwlodarski, you can do all of them and whatever you want.

@wolkykim If I change your source code (not big changes, for example add assertion, change display, or even write comments), what would you suggest

  • to rename the original file and to write in the header comment about original
  • to save the original file name and to add comments about changes

@mwlodarski Hi,
Personally, when I use 3rd party code like opensource codes in my project, I usually try not to modify the opensource code itself to make it easier to be synchronized with its mainline. I change 3rd party code only when I think my code is beneficial to their project in general and contribute that code by sending pull requests.

(not big changes, for example add assertion, change display, or even write comments)

I think those examples that you mention are beneficial to qLibc project, those work is not something related to a specific purpose but enhancing qLibc itself in general.

Whenever you find better way to improve any part of qLibc codes (that includs comments, code polishing/formatting, better variable names, ...), I highly recommend to work with main line and send pull requests. That's the way we can keep improving qLibc together and why I've published it to public domain.

Did I answer your questions?

Not exactly.
I've been thinking about application-specific changes, not improving the general project.
Changed comments & display would rather be in my language (non-english).

qLibc is aiming to serve general library areas. Just wondering what would be the application specific changes in what part in your case? Can you tell me that? I'm only asking this question to understand if there's any part of code I can improve in qLibc because as I mentioned, there should be no need to implement user land specific codes inside of qlibc and qlibc should be able to stand alone as an underlying library without any modifications.

by the way, giving a star to this project helps! :)

Don't know yet. Just started with a single file and got one idea.
I simply prefer asking before than after.

Ohu~ it's been very quiet for long years and just in a night~ Thank you @kirbyfan64

I am using the qlibc code in a couple commercial projects. I needed .ini file parsing in C++ and qlibc made it easy. Thanks.

@ tkelleher Thanks a lot for sharing your experience. I'll make sure the INI file parser to be kept well in good shape for ya.

Thank you.

On Fri, Nov 13, 2015 at 3:43 AM, wolkykim notifications@github.com wrote:

@ tkelleher Thanks a lot for sharing your experience. I'll make sure the
INI file parser to be kept well in good shape for ya.


Reply to this email directly or view it on GitHub
#4 (comment).

Terry Kelleher
Newforce Solutions
terry@newforce.us
607-351-6456

I use the containers and qdatabase for some internal projects. works great ! Thanks for your efforts