1#!/bin/bash 2# SPDX-License-Identifier: GPL-2.0 3# 4# Livepatching replaces functions, not data. A changed data symbol must be 5# rejected. 6 7. "$(dirname "$0")/../lib.sh" 8 9setup 10build_pair changed_data.c 11run_diff 255 12 13diff_log | grep -q 'changed data: klp_test_data' || 14 fail "expected rejection, got: $(diff_log | tail -1)" 15[ -e "$workdir/out.o" ] && 16 fail "output object produced for a rejected input" 17 18pass "changed data symbol rejected" 19