Module: wine
Branch: master
Commit: 07e3d538a0e1708e8f0b3f829d5f6e6fa671f86b
URL: http://source.winehq.org/git/wine.git/?a=commit;h=07e3d538a0e1708e8f0b3f829…
Author: Rob Shearman <rob(a)codeweavers.com>
Date: Fri Dec 1 15:01:38 2006 +0000
ole32: Create a cache entry for each format in the data cache to allow
for the future possiblity to add entries with IOleCache::Cache and
IOleCache::SetData.
---
dlls/ole32/datacache.c | 334 ++++++++++++++++++++++++++++++++----------------
1 files changed, 222 insertions(+), 112 deletions(-)
Diff: http://source.winehq.org/git/wine.git/?a=commitdiff;h=07e3d538a0e1708e8f0b3…
ChangeSet ID: 30241
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2006/12/03 10:26:38
Modified files:
include : maintainer.php
unit_test : test_maintainer.php
Log message:
Alexander Nicolaysen Sørnes <alex(a)thehandofagony.com>
Chris Morgan <cmorgan(a)alum.wpi.edu>
Make sure that a maintainer entry is not deleted incorrectly in Maintainer::unQueue(). If
a request has already been accepted, it is not a duplicate. Add a unit test to test the behavior of Maintainer::unQueue() on
an already unqueued maintainer.
Patch: http://cvs.winehq.org/patch.py?id=30241
Old revision New revision Changes Path
1.18 1.19 +2 -3 appdb/include/maintainer.php
1.1 1.2 +73 -1 appdb/unit_test/test_maintainer.php
Index: appdb/include/maintainer.php
diff -u -p appdb/include/maintainer.php:1.18 appdb/include/maintainer.php:1.19
--- appdb/include/maintainer.php:1.18 3 Dec 2006 16:26:38 -0000
+++ appdb/include/maintainer.php 3 Dec 2006 16:26:38 -0000
@@ -92,9 +92,8 @@ class maintainer
}
} else
{
- //delete the item from the queue
- query_parameters("DELETE from appMaintainers WHERE userId = '?' AND maintainerId = '?'",
- $this->iUserId, $this->iMaintainerId);
+ /* Delete entry, but only if queued */
+ query_parameters("DELETE from appMaintainers WHERE userId = '?' AND maintainerId = '?' AND queued = 'true'", $this->iUserId, $this->iMaintainerId);
if($oUser->isSuperMaintainer($this->iAppId) && !$this->bSuperMaintainer)
$sStatusMessage = "<p>User is already a super maintainer of this application</p>\n";
Index: appdb/unit_test/test_maintainer.php
diff -u -p appdb/unit_test/test_maintainer.php:1.1 appdb/unit_test/test_maintainer.php:1.2
--- appdb/unit_test/test_maintainer.php:1.1 3 Dec 2006 16:26:38 -0000
+++ appdb/unit_test/test_maintainer.php 3 Dec 2006 16:26:38 -0000
@@ -5,6 +5,9 @@ require_once(BASE.'include/maintainer.ph
/* unit tests for maintainer class */
+// test that the maintainer count for a given user is accurate for both
+// maintainers and super maintainers when the user is either a maintainer
+// or a super maintainer
function test_maintainer_getMaintainerCountForUser()
{
test_start(__FUNCTION__);
@@ -99,6 +102,8 @@ function test_maintainer_getMaintainerCo
return true;
}
+// test that applications a user maintains are accurately reported by
+// maintainer::GetAppsMaintained()
function test_maintainer_getAppsMaintained()
{
test_start(__FUNCTION__);
@@ -190,6 +195,67 @@ function test_maintainer_getAppsMaintain
return true;
}
+// test that unQueueing a queued maintainer request twice is ignored
+function test_maintainer_unQueue()
+{
+ test_start(__FUNCTION__);
+
+ global $test_email, $test_password;
+
+ /* login the user */
+ $oUser = new User();
+ $retval = $oUser->login($test_email, $test_password);
+ if($retval != SUCCESS)
+ {
+ echo "Got '".$retval."' instead of SUCCESS(".SUCCESS.")\n";
+ return false;
+ }
+
+ /**
+ * make the user a super maintatiner
+ */
+ $iAppId = 655000;
+ $iVersionId = 655200;
+
+ /* queue up this maintainer */
+ $oMaintainer = new Maintainer();
+ $oMaintainer->iAppId = $iAppId;
+ $oMaintainer->iVersionId = $iVersionId;
+ $oMaintainer->iUserId = $_SESSION['current']->iUserId;
+ $oMaintainer->sMaintainReason = "Some crazy reason";
+ $oMaintainer->bSuperMaintainer = TRUE;
+ $oMaintainer->create();
+
+ /* and unqueue it to accept the user as a maintainer */
+ $oMaintainer->unQueue("Some reply text");
+
+ /* unqueue it again to ensure that unQueueing a maintainer request twice works properly */
+ $oMaintainer->unQueue("Some other reply text");
+
+
+ /* see that the user is a super maintainer of the one application we added them to be */
+ $iExpected = 1; /* we expect 1 super maintainer for this user */
+ $iSuperMaintainerCount = Maintainer::getMaintainerCountForUser($oUser, TRUE);
+ if($iSuperMaintainerCount != $iExpected)
+ {
+ echo "Got super maintainer count of '".$iSuperMaintainerCount."' instead of '".$iExpected."'\n";
+ return false;
+ }
+
+ /* maintainer count should be zero */
+ $iExpected = 0;
+ $iMaintainerCount = Maintainer::getMaintainerCountForUser($oUser, FALSE);
+ if($iMaintainerCount != $iExpected)
+ {
+ echo "Got maintainer count of '".$iMaintainerCount."' instead of '".$iExpected."'\n";
+ return false;
+ }
+
+ /* remove maintainership for this user */
+ Maintainer::deleteMaintainer($oUser, $iAppId);
+
+ return true;
+}
if(!test_maintainer_getMaintainerCountForUser())
@@ -203,4 +269,10 @@ if(!test_maintainer_getAppsMaintained())
else
echo "test_maintainer_getAppsMaintained() passed\n";
-?>
\ No newline at end of file
+
+if(!test_maintainer_unQueue())
+ echo "test_maintainer_unQueue() failed!\n";
+else
+ echo "test_maintainer_unQueue() passed\n";
+
+?>
ChangeSet ID: 30240
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2006/12/02 13:44:31
Modified files:
include : config.php.sample mail.php
unit_test : run_tests.php
Log message:
Chris Morgan <cmorgan(a)alum.wpi.edu>
Unit tests should disable sending email before they execute, we don't want any accidental emails sent when developers are
running the unit tests to verify functionality. Add commented out example code that will enable developers to disable email via
a define in include/config.php
Patch: http://cvs.winehq.org/patch.py?id=30240
Old revision New revision Changes Path
1.12 1.13 +3 -0 appdb/include/config.php.sample
1.6 1.7 +5 -0 appdb/include/mail.php
1.7 1.8 +4 -0 appdb/unit_test/run_tests.php
Index: appdb/include/config.php.sample
diff -u -p appdb/include/config.php.sample:1.12 appdb/include/config.php.sample:1.13
--- appdb/include/config.php.sample:1.12 2 Dec 2006 19:44:31 -0000
+++ appdb/include/config.php.sample 2 Dec 2006 19:44:31 -0000
@@ -19,6 +19,9 @@ define("APPDB_OWNER_URL","http://www.win
define("APPDB_OWNER_EMAIL","appdb(a)winehq.org"); // e-mail of this product/company
define("BUGZILLA_ROOT","http://bugs.winehq.org/"); // path to bugzilla
+// AppDB developers: Use this define to disable email from being sent from the appdb during testing
+//if(!defined("DISABLE_EMAIL"))
+// define("DISABLE_EMAIL", true); // disable email, see mail_appdb() in include/mail.php
/*
* apps database info
Index: appdb/include/mail.php
diff -u -p appdb/include/mail.php:1.6 appdb/include/mail.php:1.7
--- appdb/include/mail.php:1.6 2 Dec 2006 19:44:31 -0000
+++ appdb/include/mail.php 2 Dec 2006 19:44:31 -0000
@@ -3,6 +3,11 @@ require_once(BASE."include/config.php");
function mail_appdb($sEmailList,$sSubject,$sMsg)
{
+ // NOTE: For AppDB developers: If email is disabled return from this function
+ // immediately. See include/config.php.sample for information
+ if(defined("DISABLE_EMAIL"))
+ return;
+
$sHeaders = "MIME-Version: 1.0\r\n";
$sHeaders .= "From: AppDB <".APPDB_OWNER_EMAIL.">\r\n";
$sHeaders .= "Reply-to: AppDB <".APPDB_OWNER_EMAIL.">\r\n";
Index: appdb/unit_test/run_tests.php
diff -u -p appdb/unit_test/run_tests.php:1.7 appdb/unit_test/run_tests.php:1.8
--- appdb/unit_test/run_tests.php:1.7 2 Dec 2006 19:44:31 -0000
+++ appdb/unit_test/run_tests.php 2 Dec 2006 19:44:31 -0000
@@ -7,6 +7,10 @@
error_reporting(E_ALL);
+// disable emailing
+if(!defined("DISABLE_EMAIL"))
+ define("DISABLE_EMAIL", true);
+
include_once("test_user.php");
echo "\n";
include_once("test_query.php");
ChangeSet ID: 30239
CVSROOT: /opt/cvs-commit
Module name: appdb
Changes by: wineowner(a)winehq.org 2006/12/02 11:28:58
Modified files:
help : generic.help
Log message:
Alexander Nicolaysen Sørnes <alex(a)thehandofagony.com>
Update the generic help page, by removing references to the wine config file
and adding some new tips. Remove references to winecheck, this was removed from wine some years ago and
remove specific 'where to get help' documentation and instead forward users to the Winehq 'getting help'
page so there is one location for this information.
Patch: http://cvs.winehq.org/patch.py?id=30239
Old revision New revision Changes Path
1.9 1.10 +11 -39 appdb/help/generic.help
Index: appdb/help/generic.help
diff -u -p appdb/help/generic.help:1.9 appdb/help/generic.help:1.10
--- appdb/help/generic.help:1.9 2 Dec 2006 17:28:58 -0000
+++ appdb/help/generic.help 2 Dec 2006 17:28:58 -0000
@@ -17,26 +17,24 @@ for a certain program doesn't exist.
</ul>
<p>
-<li> You can run winecheck this handy tool is located in the /tools directory.
-(chmod +x winecheck; ./winecheck)
-to verify the most important aspects of Wine environment configuration.</li><p>
-
<li> Run your program</li><p>
+<li> If it gives an error about missing files, or does not start at all, try running it from the directory where it was installed.</li><p>
+
+<li> Many newer games contain copy protection, which is often not supported in Wine. Cracks are available from sites such as <a href="http://www.megagames.com/trainers.html" target="_blank">MegaGames</a>.</li><p>
+
<li> In case of failure, try different builtin, native DLL settings:
Run Wine with --debugmsg +loaddll to find out which
DLLs are loaded as native or builtin.
Then make sure appropriate native versions are in the
-c:\windows\system directory as configured in your Wine
-config file. There are five options you can choose from when setting
-dll overrides, I will use commctrl here as an example.</li><p>
+c:\windows\system32 directory as configured in Winecfg’s DLL overrides tab. There are four options you can choose from when setting
+dll overrides.</li><p>
<pre>
-"commctrl" = "native, builtin"
-"commctrl" = "builtin, native "
-"commctrl" = "native"
-"commctrl" = "builtin"
-"commctrl" = ""
+(native, builtin)
+(builtin, native)
+(native)
+(builtin)
</pre>
@@ -45,33 +43,7 @@ dll overrides, I will use commctrl here
and you may also want to read the
<a href="http://www.winehq.org/site/docs/wine-faq/index">Wine FAQ</a>.</li><p>
-<li> The many different way's of getting help.</li>
-
-<ul>
-
-<li> You can ask for help on the <a href="http://www.winehq.org/mailman/listinfo/wine-users">wine-users</a>
-mailing list. </li>
-
-<li>WineHQ has a newsgroup hosted by <a href="news:comp.emulators.ms-windows.wine">Usenet</a>. You can read and post using a
-newsgroup reader such as <a href="http://www.mozilla.org/">Mozilla</a>
-or <a href="http://pan.rebelbase.com/">Pan</a>. or via the web at
-<a href="http://groups.google.com/groups?group=comp.emulators.ms-windows.wine">Google</a>.</li>
-
-<li><a href="http://www.freenode.net">Freenode.net</a> hosts a chat room for
-Wine. You can access the chat room using an IRC program such as
-<a href="http://www.xchat.org/">Xchat</a>. Use the settings listed below.</li><p>
-
-<blockquote>
- <b>Server:</b> irc.freenode.net<br>
-
- <b>Port:</b> 6667<br>
- <b>Channel:</b> #winehq<br>
-</blockquote>
-
-<li>If you use Mozilla or any other browser that supports IRC urls, you can
-join the chat by clicking on <a href="irc://irc.freenode.net/#winehq">irc://irc.freenode.net/#winehq</a>.</li><p>
-
-</ul>
+<li> The Wine <a href="http://winehq.org/site/getting_help">'Getting Help'</a> page shows the current methods of getting help with Wine.</li><p>
<li> If you have more questions, please contact us
at <a href="mailto:appdb@winehq.org">appdb(a)winehq.org</a>.</li></p>