[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
Re: gEDA-user: gerbv failure to parse sample gerber file (data attached)
On 12/18/09, Ineiev <ineiev@xxxxxxxxx> wrote:
> Try the attachment. gerbv does not recognises D2 as D02,
> despite the format documents this option.
Awfully sorry, typo in one of the modified lines.
diff --git a/src/gerber.c b/src/gerber.c
index bba2211..d91b6e1 100644
--- a/src/gerber.c
+++ b/src/gerber.c
@@ -805,11 +805,11 @@ gerber_is_rs274x_p(gerb_file_t *fd, gboolean *returnFoundBinary)
found_ADD = TRUE;
dprintf ("found_ADD\n");
}
- if (g_strstr_len(buf, len, "D00")) {
+ if (g_strstr_len(buf, len, "D00") || g_strstr_len(buf, len, "D0")) {
found_D0 = TRUE;
dprintf ("found_D0\n");
}
- if (g_strstr_len(buf, len, "D02")) {
+ if (g_strstr_len(buf, len, "D02") || g_strstr_len(buf, len, "D2")) {
found_D2 = TRUE;
dprintf ("found_D2\n");
}
@@ -904,10 +904,10 @@ gerber_is_rs274d_p(gerb_file_t *fd)
if (g_strstr_len(buf, len, "%ADD")) {
found_ADD = TRUE;
}
- if (g_strstr_len(buf, len, "D00")) {
+ if (g_strstr_len(buf, len, "D00") || g_strstr_len(buf, len, "D0")) {
found_D0 = TRUE;
}
- if (g_strstr_len(buf, len, "D02")) {
+ if (g_strstr_len(buf, len, "D02") || g_strstr_len(buf, len, "D2")) {
found_D2 = TRUE;
}
if (g_strstr_len(buf, len, "M0")) {
_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user