ports/comms/xnecview/files/patch-parse_input.c
Älven 1a3aaf2add comms/xnecview: update 1.36 => 1.37
+ Add LICENSE
* Fix MASTER_SITES and pkg-descr
* Use `make makepatch` to regenerate patches to ensure proper patch
  format

Changelog:
- a few bugfixes:
  - correctly recognize near field data in yet another nec2 version
    (Debian's) (2011)
  - show gain scale when --view option is used to choose a view along
    one of the axes. (2014-02-27)
  - calculation of absolute segment numbers when using GM cards wasi
    incorrect (tnx Luigi Tarenga)
- updates for more modern library versions
  - compatibility with libpng 1.6 instead of 1.2 (tnx Luigi Tarenga)
  - PNG file was completely black with modern libgdk (tnx Luigi Tarenga)
- fixed a few compiler warnings (one of which was probably a very subtle
  bug in the opaque drawing)

PR:		285510
Approved by:	xride (maintainer, timeout > 3 weeks)
2025-04-11 00:20:30 +03:00

19 lines
724 B
C

--- parse_input.c.orig 2020-01-12 14:16:26 UTC
+++ parse_input.c
@@ -525,6 +525,7 @@ int read_nec_SC(char *s) /* SC -> continuation of
int read_nec_SC(char *s) /* SC -> continuation of SM, SP, or SC */
{
Surface *su;
+ Surface *suLast;
int ns;
Point p3;
int n;
@@ -573,7 +574,7 @@ int read_nec_SC(char *s) /* SC -> continuation of
case 'C':
n=sscanf(s,"SC%*i%d%g%g%g%g%g%g",&ns,&su->p2.x,&su->p2.y,&su->p2.z,&su->p3.x,&su->p3.y,&su->p3.z);
if (n!=7 && n!=4) return Err_scan;
- Surface *suLast=surfaces+(numsurfaces-2);
+ suLast=surfaces+(numsurfaces-2);
su->p0=suLast->p3;
su->p1=suLast->p2;
updateextremes(&su->p2);