equal
deleted
inserted
replaced
20 */ |
20 */ |
21 |
21 |
22 /* |
22 /* |
23 * Copyright 2010 Sun Microsystems, Inc. All rights reserved. |
23 * Copyright 2010 Sun Microsystems, Inc. All rights reserved. |
24 * Use is subject to license terms. |
24 * Use is subject to license terms. |
|
25 */ |
|
26 /* |
|
27 * Copyright (c) 2012 by Delphix. All rights reserved. |
25 */ |
28 */ |
26 |
29 |
27 #include "lint.h" |
30 #include "lint.h" |
28 #include "thr_uberdata.h" |
31 #include "thr_uberdata.h" |
29 |
32 |
440 void |
443 void |
441 assfail(const char *assertion, const char *filename, int line_num) |
444 assfail(const char *assertion, const char *filename, int line_num) |
442 { |
445 { |
443 __assfail(assertion, filename, line_num); |
446 __assfail(assertion, filename, line_num); |
444 } |
447 } |
|
448 |
|
449 void |
|
450 assfail3(const char *assertion, uintmax_t lv, const char *op, uintmax_t rv, |
|
451 const char *filename, int line_num) |
|
452 { |
|
453 char buf[1000]; |
|
454 (void) strcpy(buf, assertion); |
|
455 (void) strcat(buf, " (0x"); |
|
456 ultos((uint64_t)lv, 16, buf + strlen(buf)); |
|
457 (void) strcat(buf, " "); |
|
458 (void) strcat(buf, op); |
|
459 (void) strcat(buf, " 0x"); |
|
460 ultos((uint64_t)rv, 16, buf + strlen(buf)); |
|
461 (void) strcat(buf, ")"); |
|
462 __assfail(buf, filename, line_num); |
|
463 } |