Support This Project

Submitting Patches

Have you made some changes you'd like to submit to wzdftpd Great! We'd love to see them. However some people who are unfamiliar with the process of submitting changes make it overly complicated for themselves and the developers reviewing the changes. So, in order to make things go smoothly for everyone, here are some guidelines on submitting your changes.

What is a patch?

A patch is a single file listing the changes you've made in a format that can be applied with the GNU patch tool. It will look something like this:

Index: libwzd-base/hash.c
===================================================================
--- libwzd-base/hash.c  (revision 1618)
+++ libwzd-base/hash.c  (working copy)
@@ -171,6 +171,8 @@
   CHTBL_Elmnt *entry;
   unsigned int index;

+  if (key == NULL) return -1;
+
   index = htab->h(key) % htab->containers;

   for (element=list_head(&htab->table[index]); element != NULL; element = list_next(element))

Don't worry too much about the file format, since creating and using patches can all be done easily using the right tools.

Getting started

First you'll need to get a copy of the wzdftpd source to make and test your changes. Use Subversion to get the source so that you can easily generate your patch.

Bug fixes for a current release may be added on the stable branch:

svn checkout http://svn.wzdftpd.net/svn/wzdftpd/branches/rel-0-8-patches/ wzdftpd-0.8-stable

Features should be added on the "trunk" development version:

svn checkout http://svn.wzdftpd.net/svn/wzdftpd/trunk wzdftpd-trunk

Make some changes

Go ahead and make your changes to the wzdftpd code. Test them out.

Adding files

Did you create any new files? If you only modified existing wzdftpd files you can skip this. However, if you added any new files be sure to tell Subversion you're adding them:

svn add libwzd-core/my_new_file.c

Make the patch

Simply run:

svn diff > my_patch_file.diff

This will save your changes to the file "my_patch_file.diff". Pick an appropriate filename for the changes you've made.

Submit the patch

If there is an existing ticket related to the changes you've made attach your patch file to that ticket. Otherwise please create a new ticket and attach your patch file. Be sure to provide a comment briefly explaining your changes.

Add the text "[PATCH]" at the beginning of the ticket's "Summary" field as a hint to developers that a possible patch has been provided.


See also: WzdftpdDev