- Why it is important to check what the malloc function returned - 4 Updates
- [Jesus Loves You] What Christianity is - 6 Updates
- neoGFX .. the ultimate C++ GUI library .. coming soon! - 7 Updates
- Locking file while reading/emptying it - 1 Update
- Redeclaration not an error in GCC - 1 Update
Andrey Karpov <karpov2007@gmail.com>: Feb 01 09:09AM -0800 We'd like to present the series of articles dealing with the recommendations on writing code of high quality using the examples of errors found in the Chromium project. This is the 6th part, which focuses on the malloc function. Or rather, why you should always check the pointer returned by this function. Most likely, you don't have a clue what's the catch with malloc, so we recommend looking through this article. https://www.viva64.com/en/b/0558/ |
"Chris M. Thomasson" <invalid_chris_thomasson@invalid.invalid>: Feb 01 11:59AM -0800 On 2/1/2018 9:09 AM, Andrey Karpov wrote: > We'd like to present the series of articles dealing with the recommendations on writing code of high quality using the examples of errors found in the Chromium project. This is the 6th part, which focuses on the malloc function. Or rather, why you should always check the pointer returned by this function. Most likely, you don't have a clue what's the catch with malloc, so we recommend looking through this article. https://www.viva64.com/en/b/0558/ These examples are pretty fuc%ed up man! __________________ static SubStr * SubStr_new_u(unsigned char *s, unsigned int l) { SubStr *r = malloc(sizeof(SubStr)); r->str = (char*)s; r->len = l; return r; } __________________ Sorry buddy, but you are fired! |
"Alf P. Steinbach" <alf.p.steinbach+usenet@gmail.com>: Feb 01 09:55PM +0100 On 2/1/2018 8:59 PM, Chris M. Thomasson wrote: > } > __________________ > Sorry buddy, but you are fired! That's C code (hence the lack of cast of `malloc` result, which is technically correct and preferable in C, opposite of C++: it wouldn't compile as C++, hence it must be C). Andrey evidently posted to the wrong group. He should have posted to comp.lang.c. Disclaimer: I haven't looked at the linked-to article. Cheers!, - Alf |
woodbrian77@gmail.com: Feb 01 03:21PM -0800 On Thursday, February 1, 2018 at 1:59:17 PM UTC-6, Chris M. Thomasson wrote: Please don't $wear here. Brian Ebenezer Enterprises http://webEbenezer.net |
"Shinobi" <shinobi@195:1/101.remove-tp3-this>: Jan 30 12:10PM -0700 To: Rick C. Hodgin -=> Rick C. Hodgin wrote to comp.lang.c++ <=- RCH> From Newsgroup: comp.lang.c++ RCH> Christianity divides people into two groups: RCH> Saved RCH> Unsaved RCH> All who are of the truth are led internally by God to come to His Son, RCH> repent, ask forgiveness for their sin, and they receive salvation. RCH> The rest remain firmly where they are, in sin, believing whatever lie RCH> they are willing to believe, and they are already condemned to Hell: DUDE YOU'RE OFF-TOPIC. Don't drink and post. Read the conference topic. ... (A)bort (R)etry (F)ail ___ MultiMail/Linux v0.49 --- Mystic BBS/QWK v1.12 A38 2018/01/01 (Linux/64) * Origin: Castle Rock BBS - bbs.castlerockbbs.com (195:1/101) |
"Rick C. Hodgin" <rick.c.hodgin@gmail.com>: Feb 01 05:18AM -0800 On Thursday, February 1, 2018 at 2:47:07 AM UTC-5, Shinobi wrote: > -=> [snip] > DUDE YOU'RE OFF-TOPIC. > Don't drink and post. I know it seems like I'm off-topic, but that's part of the teaching here. We all need to come to Jesus, acknowledge our sin, ask forgiveness for it, and then go forth doing the things we do in our life, but in subjection to Him and His guidance. Jesus wants us to be active members of our societies doing all of the things we have interests in ... but He wants us doing them rightly. In one of His last teachings to Christians He asked us to go forth and teach people these things, but also to teach Christians to obey everything He has commanded. Now we are living in the age of grace, which means we are not under the law and do not need to keep up its many rituals. So why would Jesus ask His disciples to obey all things whatsoever He has commanded? It's so we are not led away by the enemy, and rendered weak or impotent in our walk as Christians. So many watered down Christians exist in the world that it's very easy for someone to dismiss a professed Christian because they are likely a hypocrite or worse. But Jesus doesn't call us to be that way. And we must encourage one another to be the right kind of Christian, faithful to God, obedient on purpose and for a reason, and then going forth doing the things we are doing. I come to the places of interest I have in my life and I teach the people around me these very things. I try my level best to live them out as well, though I know I routinely fail despite my best efforts. The enemy we face is real. Without this teaching, people will only know what that enemy guides us toward. Many people will feel justified in the choices they've made because they've never taken a look at God and God's expectations of us. But if they do take that examination, they quickly realize how shoft they fall from His design for our lives. It's why this teaching is needed, so we will know the truth, and so that truth will make us free from the deception and bondage to sin we currently live in this world by the enemy's direct guidance. ----- Examine these things for yourself, Shinobi. See if we are truly supposed to have God first, and then the other things we do second. If we all did this, I wouldn't need to post because others would be constantly bringing God into their posts. "I want to thank the Lord for a very productive night of development last night," and so on. "Taste and see that the Lord is good." Until you taste for yourself, you will never truly know. Not everybody likes the same things, or dislikes the same things, and not even for the same reasons. Each person must try for themselves, and that is why this teaching is here. Don't let other people's negativity re- garding Christ prevent you from seeing for yourself. Many people have been saved that way ... because in so doing they sought to know the truth, and God Himself made sure they found it. -- Rick C. Hodgin |
"Öö Tiib" <ootiib@hot.ee>: Feb 01 06:33AM -0800 On Thursday, 1 February 2018 09:47:07 UTC+2, Shinobi wrote: > DUDE YOU'RE OFF-TOPIC. > Don't drink and post. > Read the conference topic. Rick knows that he is off-topic but he believes that he gets bonus points from his deities for posting his lunacy regularly. His deities can't communicate themselves because they are somehow locked into afterlife. The deities are waiting there and will torture people after death based on such bonus points. |
"Rick C. Hodgin" <rick.c.hodgin@gmail.com>: Feb 01 06:43AM -0800 On Thursday, February 1, 2018 at 9:33:46 AM UTC-5, Öö Tiib wrote: > because they are somehow locked into afterlife. The > deities are waiting there and will torture people after > death based on such bonus points. You are incorrect on several points. #1 There is one God. He is God the Father, God the Son, God the Holy Spirit, all in one. He is one like you are one, possessing soul, body, spirit. He is one like our bodies are one, possessing heart, brain, eyes, etc. #2 Sin is already here. We have already been condemned because of sin. What Jesus offers us is forgiveness of sin, and salvation from the punishment of sin. #3 All who receive forgiveness for sin are saved from judgment, and pass (present tense) from death to life while still here in this world. The eternal part of our being comes alive and we then have input from our spirit for the rest of our life. #4 Those who reject forgiveness remain under condemnation, and continue on the path they're on today: on their way to Hell. #5 Because we are eternal beings, and will endure forever after we leave this temporal world, our existence in Heaven will be eternal, and our existence in Hell will be eternal. #6 For those who are redeemed, we are restored to that which God intended for us before sin entered in and destroyed everything. #7 For those who are not redeemed, it is like incarceration for life. And considering the nature of sin and what it's caused in this world, and considering that an eternal being cannot die in the conventional sentence, a permanent incarceration is fully appropriate. -- Rick C. Hodgin |
"Chris M. Thomasson" <invalid_chris_thomasson@invalid.invalid>: Feb 01 12:00PM -0800 On 2/1/2018 5:18 AM, Rick C. Hodgin wrote: >> DUDE YOU'RE OFF-TOPIC. >> Don't drink and post. > I know it seems like I'm off-topic, but that's part of the teaching here. [...] Do you even know the topic of the group? Oh God. |
"Rick C. Hodgin" <rick.c.hodgin@gmail.com>: Feb 01 12:46PM -0800 On Thursday, February 1, 2018 at 3:00:41 PM UTC-5, Chris M. Thomasson wrote: > >> Don't drink and post. > > I know it seems like I'm off-topic, but that's part of the teaching here... > Do you even know the topic of the group? If you were in the military and your commanding officer told you to do X, and the head of the military had previously given you instructions to do Y, which would a good officer do? Have you ever read Matthew 28:18+ ? And what does "all power" mean? https://www.biblegateway.com/passage/?search=Matthew+28%3A18-20&version=KJV ----- There is a proper teaching here, Chris. So long as you refuse to seek the truth, it will skip right past you each time it's posted. Think, Chris! Seek out why I might post these things. Examine the very subject material itself and give it an honest examination. Consider it rather than just summarily mocking it. -- Rick C. Hodgin |
Jorgen Grahn <grahn+nntp@snipabacken.se>: Jan 31 06:30AM On Tue, 2018-01-30, Robert Wessel wrote: >>> Thanks for reminding me that the earliest UIs where flat! I'd forgotten. >>The earliest UIs had a major design constraint: they had to look good on >>monochrome displays. Motif looked kind of ugly on Sun's (excellent) monochrome displays. > Low resolution and 16-color displays pretty much also required a > flat-ish approach. I think I disagree: here's what people tended to do with four colors: http://scacom.bplaced.net/Collection/600/amiga202.png /Jorgen -- // Jorgen Grahn <grahn@ Oo o. . . \X/ snipabacken.se> O o . |
David Brown <david.brown@hesbynett.no>: Feb 01 08:40AM +0100 On 31/01/18 23:36, red floyd wrote: >> one. > Depend on if you want some unknown portions of all your activities to be > reported to Microsoft... That can be reduced by turning off the more obnoxious options, and not having a microphone on your computer. But of course you are at the mercy of Microsoft if you use their software. |
Christian Gollwitzer <auriocus@gmx.de>: Feb 01 09:28AM +0100 Am 31.01.18 um 13:28 schrieb Jorgen Grahn: > why anyone would want that. > OTOH, I don't use Windows much, and I tend to force it to use a > "Classic" theme. Well, and now consider that the programmer used QT vs. the programmer used neoGFX. The first program will adapt its look to the setting "Classic theme", the second one will not. My (originally intended) point was not that flat design it should be, but that painting your own GUI doesn't convince me. If possible, the GUI should use native widgets which look and behave like native widgets. The other thing is that fashion changes. Most people tend to get used to the modern looks, even if at first they appear odd, but when you look back there are only few people who find Windows 3.11 prettier than Windows 7, say. It is for sure that "your own GUI"(TM), no matter how well crafted it is now, will look oldfashioned soon unless you permanently redesign it. The CSS capability promised by Leigh is a bonus point; however lot of things like the shape of radiobuttons seems still hardcoded (the code draws a circle). Concerning the usability and visual hints of flat design, there are good ones and bad ones, as ususal. For instance, in OSX it is no problem to distinguish overlapping windows, because the windows themselves are flat, but they are put in 3D one above the other with shadows: https://imgur.com/a/QLtzA In addition, the active windows has coloured icons whereas the inactive have grey icons. At work, on Win7, I'm often "typing" into the wrong window because it is visually unclear where the input focus is. Christian |
Paavo Helde <myfirstname@osa.pri.ee>: Jan 31 06:12PM +0200 On 31.01.2018 14:28, Jorgen Grahn wrote: > Ah, all that. Yes, the borders between things -- even between windows > -- seem to become more and more vague in Windows. I don't understand > why anyone would want that. You are forgetting those lovely effects from semi-transparent windows. You cannot even tell the window contents apart, not to speak about borders. I especially like the semi-transparent system tray notification windows which slowly fade away, but are clickable up to some undefined time point during their fading process. |
David Brown <david.brown@hesbynett.no>: Feb 01 10:10AM +0100 On 01/02/18 09:28, Christian Gollwitzer wrote: > was not that flat design it should be, but that painting your own GUI > doesn't convince me. If possible, the GUI should use native widgets > which look and behave like native widgets. Why do you think so? There are advantages in having a program "fit in" with other programs on the same system. But there are also advantages to giving a program a consistent look wherever you run it. I don't believe there is a "right" answer to this - it is a choice with trade-offs. > permanently redesign it. The CSS capability promised by Leigh is a bonus > point; however lot of things like the shape of radiobuttons seems still > hardcoded (the code draws a circle). I don't do much customisation of gui schemes. I sometimes change the colours for virtual machines - it makes it a lot easier to avoid mixups. And I used "classic" scheme on XP because the default Teletubby interface looked ridiculous. But when I work on a computer, it is to use /applications/, not the desktop - I don't much care how that looks. (I have never set the background picture on any computer I have used - I would never see it, so what's the point?). If I want to look at something pretty, I go outside and look at the mountains - computers are tools or toys, but not works of art. All that matters for the widgets is that they are clear and easy to use. |
Mr Flibble <flibbleREMOVETHISBIT@i42.co.uk>: Jan 31 08:44PM On 31/01/2018 19:18, Rick C. Hodgin wrote: > about your kerning algorithm. I gather from your UI that it's custom. > I'd be interested in hearing your thinking on how/why you did it as > you have. If you want me to engage with you with on topic discussion then you must first stop your off topic religious spam. /Flibble -- "Suppose it's all true, and you walk up to the pearly gates, and are confronted by God," Bryne asked on his show The Meaning of Life. "What will Stephen Fry say to him, her, or it?" "I'd say, bone cancer in children? What's that about?" Fry replied. "How dare you? How dare you create a world to which there is such misery that is not our fault. It's not right, it's utterly, utterly evil." "Why should I respect a capricious, mean-minded, stupid God who creates a world that is so full of injustice and pain. That's what I would say." |
Mr Flibble <flibbleREMOVETHISBIT@i42.co.uk>: Feb 01 08:19PM On 01/02/2018 08:28, Christian Gollwitzer wrote: > was not that flat design it should be, but that painting your own GUI > doesn't convince me. If possible, the GUI should use native widgets > which look and behave like native widgets. Qt does not use native widgets either however it does use OS provided rendering library to make it look like it is using native widgets. Similarly neoGFX will have a native widget skin upon release. /Flibble -- "Suppose it's all true, and you walk up to the pearly gates, and are confronted by God," Bryne asked on his show The Meaning of Life. "What will Stephen Fry say to him, her, or it?" "I'd say, bone cancer in children? What's that about?" Fry replied. "How dare you? How dare you create a world to which there is such misery that is not our fault. It's not right, it's utterly, utterly evil." "Why should I respect a capricious, mean-minded, stupid God who creates a world that is so full of injustice and pain. That's what I would say." |
red floyd <dont.bother@its.invalid>: Jan 31 09:43AM -0800 On 1/30/2018 1:24 PM, Chris M. Thomasson wrote: >> Isn't that a PIC-32 instruction? > A PowerPC instruction eieio? > https://en.wikipedia.org/wiki/Enforce_In-order_Execution_of_I/O Thanks. It's been 10 years. It *was* PPC, not PIC. |
Manfred <noname@invalid.add>: Jan 31 02:35PM +0100 On 1/30/2018 11:33 PM, Richard wrote: >> (you are probably referring to a different version of the standard than >> n4618) > I thought n4659 was the last published draft before C++17 was accepted. Probably so, my note was only about the different section numbering. The content is not different on this matter, though. (and I believe the committee is not likely to change such basic features). |
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page. To unsubscribe from this group and stop receiving emails from it send an email to comp.lang.c+++unsubscribe@googlegroups.com. |
No comments:
Post a Comment