home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.os.linux.misc      Linux-specific topics not covered by oth      135,536 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 134,127 of 135,536   
   rbowman to vallor   
   Re: Service startup errors   
   31 Dec 25 08:24:20   
   
   From: bowman@montana.com   
      
   On Wed, 31 Dec 2025 04:40:29 +0000, vallor wrote:   
      
   > At 31 Dec 2025 03:12:29 GMT, rbowman  wrote:   
   >   
   >> On Tue, 30 Dec 2025 18:53:56 GMT, Charlie Gibbs wrote:   
   >>   
   >> > But if it means something to them, it's still miles ahead of a   
   >> > "something went wrong" message.  If you're lucky you might find a   
   >> > list of what the error codes mean.   
   >>   
   >> https://www.thegeekstuff.com/2010/10/linux-error-codes/   
   >>   
   >> printf("Oh shit! %s\n", strerror(errno));   
   >   
   > Some of those look a bit silly when errno is 0...   
   >   
   > ("Oh shit!  Success")   
      
   There is usually a conditional.   
      
   void* foo;   
      
   foo = malloc(1000);   
   if (foo == NULL) {   
   	printf("malloc had a little problem %s\n", strerror(errno));   
   }   
      
   I usually did test malloc/calloc returns and logged the error although if   
   malloc was failing I was skeptical of the log ever being written. I do   
   remember catching a calloc() error where the number of elements was less   
   than 0 so I guess it wasn't in vain.   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca