Changeset 4970:5fd50d4ef2ea in roaraudio for libroar/libroar.c
- Timestamp:
- 05/16/11 13:50:52 (13 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libroar/libroar.c
r4965 r4970 161 161 } 162 162 163 void roar_panic_real(enum roar_fatal_error error, const char * info, 164 unsigned long int line, const char * file, const char * prefix, const char * func) { 165 const char * errname = NULL; 166 //#define ROAR_ERR(format, args...) roar_debug_msg(ROAR_DEBUG_TYPE_ERROR, __LINE__, __FILE__, ROAR_DBG_PREFIX, format, ## args) 167 168 if ( func == NULL ) 169 func = "<unknown>"; 170 171 switch (error) { 172 case ROAR_FATAL_ERROR_MEMORY_CORRUPTION_GUARD: 173 roar_debug_msg(ROAR_DEBUG_TYPE_ERROR, line, file, prefix, "in %s() a guard segment memory corruption has happened. Backup your data and terminate this program. Report this lion to developer. Thanks.", func); 174 return; 175 break; 176 case ROAR_FATAL_ERROR_UNKNOWN: 177 errname = "<unknown error>"; 178 break; 179 case ROAR_FATAL_ERROR_MEMORY_CORRUPTION: 180 errname = "Memory corruption"; 181 break; 182 case ROAR_FATAL_ERROR_CPU_FAILTURE: 183 errname = "CPU failture, replace hardware"; 184 break; 185 default: 186 errname = "<unknown error code, BAD>"; 187 break; 188 } 189 190 roar_debug_msg(ROAR_DEBUG_TYPE_ERROR, line, file, prefix, "in %s() a _FATAL_ error of type \"%s\" happend. Terminating program. Report this lion to developer. Thanks.", func, errname); 191 192 #ifdef SIGKILL 193 raise(SIGKILL); 194 #endif 195 abort(); 196 197 while(1); 198 } 199 163 200 //ll
Note: See TracChangeset
for help on using the changeset viewer.