comparison src/c/urweb.c @ 1483:ebc30bb262d0

For non-debug builds, leave out source location info in what is shown to user
author Adam Chlipala <adam@chlipala.net>
date Sun, 03 Jul 2011 12:40:00 -0400
parents 3d0cc841cafd
children 4300592e6803
comparison
equal deleted inserted replaced
1482:8314f1a309e7 1483:ebc30bb262d0
3892 } 3892 }
3893 3893
3894 void uw_mayReturnIndirectly(uw_context ctx) { 3894 void uw_mayReturnIndirectly(uw_context ctx) {
3895 ctx->allowed_to_return_indirectly = 1; 3895 ctx->allowed_to_return_indirectly = 1;
3896 } 3896 }
3897
3898 void uw_cutErrorLocation(char *s) {
3899 char *s2;
3900
3901 s2 = strstr(s, ": ");
3902 if (s2 == NULL || strcspn(s, "<&") < s2 - s)
3903 return;
3904
3905 memmove(s, s2+2, strlen(s2+2)+1);
3906 }