Mercurial > pidgin
annotate libpurple/purple-send-async @ 25430:9c96fb57632d
Fix a null ptr deref/double free. Fixes #8336.
author | Daniel Atallah <daniel.atallah@gmail.com> |
---|---|
date | Fri, 06 Feb 2009 03:50:26 +0000 |
parents | 942bf314fc8a |
children | 584063555949 |
rev | line source |
---|---|
22014
942bf314fc8a
These don't seem to require bash.
Richard Laager <rlaager@wiktel.com>
parents:
16143
diff
changeset
|
1 #!/bin/sh |
15884
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
2 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
3 METHOD_NAME=$1 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
4 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
5 if test -z "$METHOD_NAME" |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
6 then |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
7 cat <<EOF |
16143
598b1b15b199
Trac Ticket #149 from JensenDied
Richard Laager <rlaager@wiktel.com>
parents:
15884
diff
changeset
|
8 This program calls purple API functions using DBus. As opposed to purple-send, |
15884
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
9 it does not print the return value. |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
10 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
11 Usage: |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
12 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
13 $0 method-name type1:parameter1 type2:parameter2 ... |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
14 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
15 This shell script just invokes dbus-send, see man dbus-send for how |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
16 to specify the parameters. |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
17 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
18 Examples: |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
19 |
16143
598b1b15b199
Trac Ticket #149 from JensenDied
Richard Laager <rlaager@wiktel.com>
parents:
15884
diff
changeset
|
20 $0 PurpleCoreQuit |
15884
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
21 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
22 Use dbus-viewer to get the list of supported functions and their parameters. |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
23 EOF |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
24 exit 1 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
25 fi |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
26 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
27 shift |
16143
598b1b15b199
Trac Ticket #149 from JensenDied
Richard Laager <rlaager@wiktel.com>
parents:
15884
diff
changeset
|
28 dbus-send --dest=im.pidgin.purple.PurpleService --type=method_call /im/pidgin/purple/PurpleObject im.pidgin.purple.PurpleInterface.$METHOD_NAME "$@" |
15884
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
29 |
c6e563dfaa7a
More s/gaim/pidgin/ and s/gaim/purple/ and make the RPM spec file work a bit
Stu Tomlinson <stu@nosnilmot.com>
parents:
diff
changeset
|
30 echo |