lwIP - A Lightweight TCP/IP stack - Tasks: task #6933, Review usage of ASSERT and error...
You are not allowed to post comments on this tracker with your current authentication level.
task #6933: Review usage of ASSERT and error handling with LWIP_NOASSERT
Submitter: | Simon Goldschmidt <goldsimon> | ||
Submitted: | Thu 24 May 2007 07:22:12 AM UTC | ||
Category: | None | Should Start On: | Thu 24 May 2007 12:00:00 AM UTC |
Should be Finished on: | Thu 24 May 2007 12:00:00 AM UTC | Priority: | 1 - Later |
Status: | Done | Privacy: | Public |
Assigned to: | goldsimon | Percent Complete: | 100% |
Open/Closed: | Closed | Planned Release: | None |
Effort: | 0.00 |
Jump to the original submission
Mon 02 Jul 2007 07:19:50 PM UTC, comment #23: |
Simon Goldschmidt <goldsimon> |
Fri 22 Jun 2007 08:07:49 PM UTC, comment #22: OK, I'll start with that now. |
Simon Goldschmidt <goldsimon> |
Thu 21 Jun 2007 09:15:59 PM UTC, comment #21: Finally, you don't want to chnage LWIP_ERROR semantics now?
|
Frédéric Bernon <fbernon> |
Thu 21 Jun 2007 07:43:05 PM UTC, comment #20: I think this is done and can be closed. Does anyone think different? |
Simon Goldschmidt <goldsimon> |
Mon 18 Jun 2007 04:07:08 PM UTC, comment #19:
|
Simon Goldschmidt <goldsimon> |
Mon 18 Jun 2007 07:48:58 AM UTC, comment #18: A question about some asserts I seen. Take this sample from pbuf_free:
|
Frédéric Bernon <fbernon> |
Sun 17 Jun 2007 07:10:49 PM UTC, comment #17: I think I've finished... didn't change LWIP_ERROR semantics yet. |
Simon Goldschmidt <goldsimon> |
Sun 17 Jun 2007 03:33:17 PM UTC, comment #16: Ok, post a comment when you think you have terminate, I will check your change to be sure all is ok if you want...
|
Frédéric Bernon <fbernon> |
Sun 17 Jun 2007 02:53:11 PM UTC, comment #15: Maybe we should reaqlly change LWIP_ERROR to LWIP_ASSERT semantics now, as LWIP_PLATFORM_ASSERT is called, which prints something like "Assertion %s has failed" and that is very misleading for the current LWIP_ERROR... |
Simon Goldschmidt <goldsimon> |
Sun 17 Jun 2007 02:50:44 PM UTC, comment #14:
|
Simon Goldschmidt <goldsimon> |
Sun 17 Jun 2007 02:39:47 PM UTC, comment #13:
|
Frédéric Bernon <fbernon> |
Sun 17 Jun 2007 02:29:25 PM UTC, comment #12: Frédéric, is it OK for you to change
|
Simon Goldschmidt <goldsimon> |
Wed 13 Jun 2007 04:03:35 PM UTC, comment #11:
|
Frédéric Bernon <fbernon> |
Wed 13 Jun 2007 01:17:35 PM UTC, comment #10:
|
Simon Goldschmidt <goldsimon> |
Wed 13 Jun 2007 01:03:27 PM UTC, comment #9:
|
Frédéric Bernon <fbernon> |
Wed 13 Jun 2007 10:46:21 AM UTC, comment #8: While I can understand Frédéric's need for a faster stack (and leaving away 'double' checks), I still think it is necessary to have some argument checks. Because of that, I wouldn't call it LWIP_FATAL. Giving a wrong argument isn't fatal.
|
Simon Goldschmidt <goldsimon> |
Tue 12 Jun 2007 05:47:56 PM UTC, comment #7: (It's a bit longer, sorry, but I hope to be clear about what I think, and my english is not very good ;) )
|
Frédéric Bernon <fbernon> |
Tue 12 Jun 2007 03:41:53 PM UTC, comment #6: Just to make sure I understand what your suggesting Frederic, which bit of the following example do you think shouldn't be there?
|
Kieran Mansley <kieranm> |
Tue 12 Jun 2007 03:31:45 PM UTC, comment #5:
|
Frédéric Bernon <fbernon> |
Tue 12 Jun 2007 03:21:34 PM UTC, comment #4: I like the look of Simon's patch. We get both assertions when there is a programmer error in a debug build, and robust error returns (rather than just carrying on blindly) if there is such an error in release code.
|
Kieran Mansley <kieranm> |
Mon 11 Jun 2007 12:39:42 PM UTC, comment #3: The change was done due to this patch:
|
Frédéric Bernon <fbernon> |
Mon 11 Jun 2007 12:20:11 PM UTC, comment #2: For api_lib.c patch, I'm disagree with you: we have replace the "conn==NULL" check by assert, because it's most an application programmer task (always done when you have good developers in your team) and it's redundant here (more cycles & footprint).
|
Frédéric Bernon <fbernon> |
Mon 11 Jun 2007 10:55:25 AM UTC, comment #1: I've put together a patch of places I would return error values in addition to asserting to keep the stack working with LWIP_NOASSERT.
|
Simon Goldschmidt <goldsimon> |
Thu 24 May 2007 07:22:12 AM UTC, original submission:
At least some part of the stack might not handle errors correctly if compiled with LWIP_NOASSERT.
|
Simon Goldschmidt <goldsimon> |
Depends on the following items: None found
Items that depend on this one: None found
There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.
Follow 5 latest changes.
Date | Changed by | Updated Field | Previous Value | => | Replaced by |
---|---|---|---|---|---|
2007-07-02 | goldsimon | Status | None | Done | |
Percent Complete | 0% | 100% | |||
Assigned to | None | goldsimon | |||
Open/Closed | Open | Closed | |||
2007-06-11 | goldsimon | Attached File | - | Added noassert.patch, #13009 |
Powered by Savane 3.13-d3ae.
Corresponding source code
Ooops, this is still set to 0% :-)
I think I've checked pretty much all asserts (everything but ppp) and converted some of them to LWIP_ERROR.
I regard this as done.