Nп/п : 27 из 100
 От   : Pancho                              2:5075/128        15 сен 23 12:19:45
 К    : The Natural Philosopher                               15 сен 23 14:21:02
 Тема : Re: Weird code crash
----------------------------------------------------------------------------------
                                                                                 
@MSGID: 2@dont-email.me> 65c4c22a
@REPLY: 1@dont-email.me> f9a7c029
@REPLYADDR Pancho <Pancho.Jones@proton.me>
@REPLYTO 2:5075/128 Pancho
@CHRS: CP866 2
@RFC: 1 0
@RFC-Message-ID: 2@dont-email.me>
@RFC-References: 1@dont-email.me>
53kqz@news.chiark.greenend.org.uk> <wwv8r99b1ui.fsf@LkoBDZeT.terraraq.uk> 1@dont-email.me>
<wwvpm2jgagf.fsf@LkoBDZeT.terraraq.uk> 1@dont-email.me>
@TZUTC: 0100
@PID: Mozilla/5.0 (Windows NT 10.0; Win64; x64;
rv:102.0) Gecko/20100101 Thunderbird/102.14.0
@TID: FIDOGATE-5.12-ge4e8b94
On 15/09/2023 10:46, The Natural Philosopher wrote:
> On 15/09/2023 08:30, Richard Kettlewell wrote:
>> The Natural Philosopher <tnp@invalid.invalid> writes:
>>> On 14/09/2023 09:23, Richard Kettlewell wrote:
>>>> Also:
>>>> * I would also have a look at the kernel log; if it`s a
>>>>    kernel-generated signal then there`s usually a log message about it.
>>>>
>>> Nothing in kern.log after the boot process finishes.
>>
>> Most likely a bug in your program then.
>>
>>>> * Run the application under valgrind; depending what the issue is, that
>>>>     will provide a backtrace and perhaps more detailed information. 
>>>> If it
>>>>     is a memory corruption issue then it may identify where the 
>>>> corruption
>>>>     happens, rather than the later point where malloc failed a 
>>>> consistency
>>>>     check (or whatever it is).
>>>>
>>>> Using valgrind (and/or compiler sanitizer features) is a good idea
>>>> even before running into trouble, really.
>>>
>>> The strange thing is that it failed once after a minute, then I
>>> rebooted and it failed after 20 minutes, and its been running several
>>> days now with no issues at all.
>>>
>>> I am not sure valgrind would actually help unless it failed.
>>
>> It`s extremely good at identifying memory corruption even in cases where
>> that doesn`t immediately lead to a crash; that`s what it`s for.  But if
>> it doesn`t, you leave it running until the crash happens.
>>
> Well that is an option for sure.


Valgrind seems to be a modern version of Purify, which was absolutely 
essential, when I programmed C 30 years ago.

Personally, I want to run with full debug, stack trace, logging, 
exception handling, and bounds checking turned on all the time, even in 
production. Which is why I generally use a modern language like C# or Java.

I`m with you on Python being rubbish, but have you considered something 
like Rust? That gives you the benefit of a modern language, without 
Garbage Collection pauses (if you care), or the need for a runtime 
environment (like Python, C#, and Java).

Even using C++, would give you exception handling. C++ won`t force you 
to go too far, If you don`t want to.
 --- Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101
Thunderbird/102.14.0
 * Origin: A noiseless patient Spider (2:5075/128)
SEEN-BY: 5001/100 5005/49 5015/255 5019/40 5020/715
848 1042 4441 12000
SEEN-BY: 5030/49 1081 5058/104 5075/128
@PATH: 5075/128 5020/1042 4441



   GoldED+ VK   │                                                 │   09:55:30    
                                                                                
В этой области больше нет сообщений.

Остаться здесь
Перейти к списку сообщений
Перейти к списку эх