Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Oct 2001 13:39:19 -0700 (PDT)
From:      Alan Larson <larson@eng.paix.net>
To:        freebsd-bugs@freebsd.org
Subject:   problem with patch
Message-ID:  <200110232039.NAA90656@ground0.paix.net>

next in thread | raw e-mail | index | archive | help
  I just happened across a problem with the patch utility.

  Running the appended script with a freshly installed 4.4-release
causes patch to give an error message and a core file.

It says:
Patching file LOCAL using Plan A...
assertion "fillsrc==p_end+1 || fillsrc==repl_beginning" failed: "/usr/src/gnu/usr.bin/patch/pch.c", line 768
Abort (core dumped)


  I would claim that this is the wrong response.


  Note, some sort of error is appropriate -- the patch file is for
4.3-release, and doesn't match the file that is being patched.

	Alan



#!/bin/csh -x

# make a kernel

cd /sys/i386/conf

if ( -f LOCAL ) exit

cp -p GENERIC LOCAL

patch << '---EOF---'
*** LOCAL	Tue Oct 31 15:16:07 2000
--- LOCAL	Thu Jun 21 07:18:54 2001
***************
*** 170,175 ****
--- 170,178 ----
  device		tx		# SMC 9432TX (83c170 ``EPIC'')
  device		vx		# 3Com 3c590, 3c595 (``Vortex'')
  device		wx		# Intel Gigabit Ethernet Card (``Wiseman'')
+ device		ti		# Netgear Gigabit Ethernet Card (GA620)
+ device		rp		# Comtrol Rocketport PCI Card
  
  # PCI Ethernet NICs that use the common MII bus controller code.
  # NOTE: Be sure to keep the 'device miibus' line in order to use these NICs!
'---EOF---'

if ( $status != 0 ) then
 echo patch failed, exiting
 exit 1
endif

rm -f LOCAL LOCAL.orig

# for our purposes, the rest of the script is not needed

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200110232039.NAA90656>