VirtualBox

source: vbox/trunk/src/VBox/Runtime/errmsgcom.sed@ 4394

Last change on this file since 4394 was 4071, checked in by vboxsync, 17 years ago

Biggest check-in ever. New source code headers for all (C) innotek files.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 1.2 KB
Line 
1# $Id: errmsgcom.sed 4071 2007-08-07 17:07:59Z vboxsync $
2## @file
3# innotek Portable Runtime - SED script for converting COM errors
4#
5
6# Copyright (C) 2006-2007 innotek GmbH
7#
8# This file is part of VirtualBox Open Source Edition (OSE), as
9# available from http://www.virtualbox.org. This file is free software;
10# you can redistribute it and/or modify it under the terms of the GNU
11# General Public License as published by the Free Software Foundation,
12# in version 2 as it comes in the "COPYING" file of the VirtualBox OSE
13# distribution. VirtualBox OSE is distributed in the hope that it will
14# be useful, but WITHOUT ANY WARRANTY of any kind.
15
16# we only care about message definitions
17\/\/ MessageId: /b messageid
18d
19b end
20
21
22# Everything else is deleted!
23d
24b end
25
26
27#
28# A message ID we care about
29#
30:messageid
31# concatenate the next four lines to the string
32N
33N
34N
35N
36{
37 # remove DOS <CR>.
38 s/\r//g
39 # remove the message ID
40 s/\/\/ MessageId: //g
41 # remove the stuff in between
42 s/\/\/\n\/\/ MessageText:\n\/\/\n\/\/ //g
43 # backslashes have to be escaped
44 s/\\/\\\\/g
45 # double quotes have to be escaped, too
46 s/"/\\"/g
47 # output C array entry
48 s/\([a-zA-Z0-9_]*\)[\t ]*\n\(.*\)[\t ]*$/{ "\2", "\1", \1 }, /
49}
50b end
51
52# next expression
53:end
Note: See TracBrowser for help on using the repository browser.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette