From 2a2206f128cdd3ef136166e586026c774da5c490 Mon Sep 17 00:00:00 2001 From: short <> Date: Sun, 17 Mar 2002 20:29:24 +0000 Subject: [PATCH] http://marcin-wiacek.fkn.pl/english/zips/mygnokii.tar.gz md5sum: 4222bc7d869a6778f5dc21a37a69795a length: 1121269 --- COPYING | 356 +++++++++++++++++++++++++++++++++++++++++++++---- Docs/CREDITS | 2 +- INSTALL | 10 +- VERSION | 2 +- common/Makefile | 2 + common/gsm-api.c | 20 ++- common/gsm-networks.c | 74 +++++----- common/gsm-ringtones.c | 110 +++++++-------- common/gsm-sms.c | 10 +- common/misc.c | 99 +------------- gnokii/gnokii.c | 85 ++++++------ include/gsm-api.h | 33 ++--- include/gsm-common.h | 5 +- xgnokii/xgnokii_sms.c | 8 +- 14 files changed, 530 insertions(+), 286 deletions(-) diff --git a/COPYING b/COPYING index 049061c..60549be 100644 --- a/COPYING +++ b/COPYING @@ -1,30 +1,340 @@ -GNOKII - A Linux/Unix toolset and driver for the Nokia 3x10/8110/51x0/61x0 - Copyright (C) 1999 Hugh Blemings & Pavel Janík ml. + GNU GENERAL PUBLIC LICENSE + Version 2, June 1991 -This program is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free Software -Foundation; either version 2 of the License, or (at your option) any later -version. + Copyright (C) 1989, 1991 Free Software Foundation, Inc. + 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. -This program is distributed in the hope that it will be useful, but WITHOUT -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS -FOR A PARTICULAR PURPOSE. See the GNU General Public License for more -details. + Preamble -You should have received a copy of the GNU General Public License along with -this program; if not, write to the Free Software Foundation, Inc., 59 Temple -Place - Suite 330, Boston, MA 02111-1307, USA. + The licenses for most software are designed to take away your +freedom to share and change it. By contrast, the GNU General Public +License is intended to guarantee your freedom to share and change free +software--to make sure the software is free for all its users. This +General Public License applies to most of the Free Software +Foundation's software and to any other program whose authors commit to +using it. (Some other Free Software Foundation software is covered by +the GNU Library General Public License instead.) You can apply it to +your programs, too. -You can contact authors by mail at + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +this service if you wish), that you receive source code or can get it +if you want it, that you can change the software or use pieces of it +in new free programs; and that you know you can do these things. -hugh@linuxcare.com Pavel.Janik@suse.cz -Hugh Blemings Mgr. Pavel Janík, SuSE CR, s.r.o. -PO Box 234 Pod Pekárnami 338/12 -Belconnen ACT 2616 190 00 Praha 9 -Australia Czech Republic + To protect your rights, we need to make restrictions that forbid +anyone to deny you these rights or to ask you to surrender the rights. +These restrictions translate to certain responsibilities for you if you +distribute copies of the software, or if you modify it. -We would be delighted to receive a postcard from you if you use gnokii but -this is not a requirement of these licence terms! :) + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must give the recipients all the rights that +you have. You must make sure that they, too, receive or can get the +source code. And you must show them these terms so they know their +rights. -Any trademarks in this or other gnokii documents/files are the property of -their respective owners. + We protect your rights with two steps: (1) copyright the software, and +(2) offer you this license which gives you legal permission to copy, +distribute and/or modify the software. + + Also, for each author's protection and ours, we want to make certain +that everyone understands that there is no warranty for this free +software. If the software is modified by someone else and passed on, we +want its recipients to know that what they have is not the original, so +that any problems introduced by others will not reflect on the original +authors' reputations. + + Finally, any free program is threatened constantly by software +patents. We wish to avoid the danger that redistributors of a free +program will individually obtain patent licenses, in effect making the +program proprietary. To prevent this, we have made it clear that any +patent must be licensed for everyone's free use or not licensed at all. + + The precise terms and conditions for copying, distribution and +modification follow. + + GNU GENERAL PUBLIC LICENSE + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION + + 0. This License applies to any program or other work which contains +a notice placed by the copyright holder saying it may be distributed +under the terms of this General Public License. The "Program", below, +refers to any such program or work, and a "work based on the Program" +means either the Program or any derivative work under copyright law: +that is to say, a work containing the Program or a portion of it, +either verbatim or with modifications and/or translated into another +language. (Hereinafter, translation is included without limitation in +the term "modification".) Each licensee is addressed as "you". + +Activities other than copying, distribution and modification are not +covered by this License; they are outside its scope. The act of +running the Program is not restricted, and the output from the Program +is covered only if its contents constitute a work based on the +Program (independent of having been made by running the Program). +Whether that is true depends on what the Program does. + + 1. You may copy and distribute verbatim copies of the Program's +source code as you receive it, in any medium, provided that you +conspicuously and appropriately publish on each copy an appropriate +copyright notice and disclaimer of warranty; keep intact all the +notices that refer to this License and to the absence of any warranty; +and give any other recipients of the Program a copy of this License +along with the Program. + +You may charge a fee for the physical act of transferring a copy, and +you may at your option offer warranty protection in exchange for a fee. + + 2. You may modify your copy or copies of the Program or any portion +of it, thus forming a work based on the Program, and copy and +distribute such modifications or work under the terms of Section 1 +above, provided that you also meet all of these conditions: + + a) You must cause the modified files to carry prominent notices + stating that you changed the files and the date of any change. + + b) You must cause any work that you distribute or publish, that in + whole or in part contains or is derived from the Program or any + part thereof, to be licensed as a whole at no charge to all third + parties under the terms of this License. + + c) If the modified program normally reads commands interactively + when run, you must cause it, when started running for such + interactive use in the most ordinary way, to print or display an + announcement including an appropriate copyright notice and a + notice that there is no warranty (or else, saying that you provide + a warranty) and that users may redistribute the program under + these conditions, and telling the user how to view a copy of this + License. (Exception: if the Program itself is interactive but + does not normally print such an announcement, your work based on + the Program is not required to print an announcement.) + +These requirements apply to the modified work as a whole. If +identifiable sections of that work are not derived from the Program, +and can be reasonably considered independent and separate works in +themselves, then this License, and its terms, do not apply to those +sections when you distribute them as separate works. But when you +distribute the same sections as part of a whole which is a work based +on the Program, the distribution of the whole must be on the terms of +this License, whose permissions for other licensees extend to the +entire whole, and thus to each and every part regardless of who wrote it. + +Thus, it is not the intent of this section to claim rights or contest +your rights to work written entirely by you; rather, the intent is to +exercise the right to control the distribution of derivative or +collective works based on the Program. + +In addition, mere aggregation of another work not based on the Program +with the Program (or with a work based on the Program) on a volume of +a storage or distribution medium does not bring the other work under +the scope of this License. + + 3. You may copy and distribute the Program (or a work based on it, +under Section 2) in object code or executable form under the terms of +Sections 1 and 2 above provided that you also do one of the following: + + a) Accompany it with the complete corresponding machine-readable + source code, which must be distributed under the terms of Sections + 1 and 2 above on a medium customarily used for software interchange; or, + + b) Accompany it with a written offer, valid for at least three + years, to give any third party, for a charge no more than your + cost of physically performing source distribution, a complete + machine-readable copy of the corresponding source code, to be + distributed under the terms of Sections 1 and 2 above on a medium + customarily used for software interchange; or, + + c) Accompany it with the information you received as to the offer + to distribute corresponding source code. (This alternative is + allowed only for noncommercial distribution and only if you + received the program in object code or executable form with such + an offer, in accord with Subsection b above.) + +The source code for a work means the preferred form of the work for +making modifications to it. For an executable work, complete source +code means all the source code for all modules it contains, plus any +associated interface definition files, plus the scripts used to +control compilation and installation of the executable. However, as a +special exception, the source code distributed need not include +anything that is normally distributed (in either source or binary +form) with the major components (compiler, kernel, and so on) of the +operating system on which the executable runs, unless that component +itself accompanies the executable. + +If distribution of executable or object code is made by offering +access to copy from a designated place, then offering equivalent +access to copy the source code from the same place counts as +distribution of the source code, even though third parties are not +compelled to copy the source along with the object code. + + 4. You may not copy, modify, sublicense, or distribute the Program +except as expressly provided under this License. Any attempt +otherwise to copy, modify, sublicense or distribute the Program is +void, and will automatically terminate your rights under this License. +However, parties who have received copies, or rights, from you under +this License will not have their licenses terminated so long as such +parties remain in full compliance. + + 5. You are not required to accept this License, since you have not +signed it. However, nothing else grants you permission to modify or +distribute the Program or its derivative works. These actions are +prohibited by law if you do not accept this License. Therefore, by +modifying or distributing the Program (or any work based on the +Program), you indicate your acceptance of this License to do so, and +all its terms and conditions for copying, distributing or modifying +the Program or works based on it. + + 6. Each time you redistribute the Program (or any work based on the +Program), the recipient automatically receives a license from the +original licensor to copy, distribute or modify the Program subject to +these terms and conditions. You may not impose any further +restrictions on the recipients' exercise of the rights granted herein. +You are not responsible for enforcing compliance by third parties to +this License. + + 7. If, as a consequence of a court judgment or allegation of patent +infringement or for any other reason (not limited to patent issues), +conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot +distribute so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you +may not distribute the Program at all. For example, if a patent +license would not permit royalty-free redistribution of the Program by +all those who receive copies directly or indirectly through you, then +the only way you could satisfy both it and this License would be to +refrain entirely from distribution of the Program. + +If any portion of this section is held invalid or unenforceable under +any particular circumstance, the balance of the section is intended to +apply and the section as a whole is intended to apply in other +circumstances. + +It is not the purpose of this section to induce you to infringe any +patents or other property right claims or to contest validity of any +such claims; this section has the sole purpose of protecting the +integrity of the free software distribution system, which is +implemented by public license practices. Many people have made +generous contributions to the wide range of software distributed +through that system in reliance on consistent application of that +system; it is up to the author/donor to decide if he or she is willing +to distribute software through any other system and a licensee cannot +impose that choice. + +This section is intended to make thoroughly clear what is believed to +be a consequence of the rest of this License. + + 8. If the distribution and/or use of the Program is restricted in +certain countries either by patents or by copyrighted interfaces, the +original copyright holder who places the Program under this License +may add an explicit geographical distribution limitation excluding +those countries, so that distribution is permitted only in or among +countries not thus excluded. In such case, this License incorporates +the limitation as if written in the body of this License. + + 9. The Free Software Foundation may publish revised and/or new versions +of the General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + +Each version is given a distinguishing version number. If the Program +specifies a version number of this License which applies to it and "any +later version", you have the option of following the terms and conditions +either of that version or of any later version published by the Free +Software Foundation. If the Program does not specify a version number of +this License, you may choose any version ever published by the Free Software +Foundation. + + 10. If you wish to incorporate parts of the Program into other free +programs whose distribution conditions are different, write to the author +to ask for permission. For software which is copyrighted by the Free +Software Foundation, write to the Free Software Foundation; we sometimes +make exceptions for this. Our decision will be guided by the two goals +of preserving the free status of all derivatives of our free software and +of promoting the sharing and reuse of software generally. + + NO WARRANTY + + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, +REPAIR OR CORRECTION. + + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE +POSSIBILITY OF SUCH DAMAGES. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +convey the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) 19yy + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + + +Also add information on how to contact you by electronic and paper mail. + +If the program is interactive, make it output a short notice like this +when it starts in an interactive mode: + + Gnomovision version 69, Copyright (C) 19yy name of author + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, the commands you use may +be called something other than `show w' and `show c'; they could even be +mouse-clicks or menu items--whatever suits your program. + +You should also get your employer (if you work as a programmer) or your +school, if any, to sign a "copyright disclaimer" for the program, if +necessary. Here is a sample; alter the names: + + Yoyodyne, Inc., hereby disclaims all copyright interest in the program + `Gnomovision' (which makes passes at compilers) written by James Hacker. + + , 1 April 1989 + Ty Coon, President of Vice + +This General Public License does not permit incorporating your program into +proprietary programs. If your program is a subroutine library, you may +consider it more useful to permit linking proprietary applications with the +library. If this is what you want to do, use the GNU Library General +Public License instead of this License. diff --git a/Docs/CREDITS b/Docs/CREDITS index 7193775..8232bd3 100644 --- a/Docs/CREDITS +++ b/Docs/CREDITS @@ -89,7 +89,7 @@ Thank you to, in no particular order... * Balazs Nagy for frames list and long hacker's work... -* Ladislav Michl & Manfred Jonsson for support for various AT phones... +* Ladislav Michl & Manfred Jonsson for support for various AT phones... * Manfred Jonsson for idea of programming, which looks for me good diff --git a/INSTALL b/INSTALL index 3551ce2..7d5654f 100644 --- a/INSTALL +++ b/INSTALL @@ -16,7 +16,7 @@ Install path prefix. Default /usr/local/ --without-x - Compile without GTK (Xwin) programs + Compile without GTK (X11) programs --disable-nls Set if you don't have/want GNU gettext support @@ -34,15 +34,17 @@ Good default (example): ./configure --prefix=/usr \ - --enable-gettext + --enable-security 2/ compilation: - make + make (or make gnokii-debug to create staticlly linked binary + -- mainly for debugging) groupadd gnokii - it is really needed (make dep - if you want/need) - make install + make install or make install-suid or make install-strip or + make install-ss (suid + strip) make install-docs clean source: diff --git a/VERSION b/VERSION index 3a1e380..2a8e926 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.3.3_pre8-gold_2002_02_24 +0.3.3_pre8-gold_2002_03_10 diff --git a/common/Makefile b/common/Makefile index e396803..2dad729 100644 --- a/common/Makefile +++ b/common/Makefile @@ -35,12 +35,14 @@ OBJS = devices/device.o \ files/cfgreader.o \ misc.o \ protocol/fbus.o \ + protocol/fbus3110.o \ protocol/fbusirda.o \ protocol/mbus.o \ protocol/at.o \ newmodules/sniff/sniff.o \ newmodules/newat.o \ newmodules/n6110.o \ + newmodules/n3110.o \ newmodules/n7110.o DATA_OBJS = data/virtmodem.o \ diff --git a/common/gsm-api.c b/common/gsm-api.c index 5a91da9..3c090a0 100644 --- a/common/gsm-api.c +++ b/common/gsm-api.c @@ -30,6 +30,7 @@ #include "gsm-api.h" +#include "newmodules/n3110.h" #include "newmodules/n6110.h" #include "newmodules/n7110.h" #include "newmodules/newat.h" @@ -38,6 +39,7 @@ #endif #include "protocol/fbusirda.h" #include "protocol/fbus.h" +#include "protocol/fbus3110.h" #include "protocol/mbus.h" #include "protocol/at.h" #include "files/cfgreader.h" @@ -247,6 +249,9 @@ bool CheckModel (GSM_Information InfoToCheck, char *model, GSM_ConnectionType co if (strstr(InfoToCheck.TekramModels, model) != NULL) { if (connection==GCT_Tekram) found_match=true; } + if (strstr(InfoToCheck.FBUS3110Models, model) != NULL) { + if (connection==GCT_FBUS3110) found_match=true; + } return found_match; } @@ -298,7 +303,8 @@ GSM_Error TryNewNokia(char *model, char *device, char *initlength, GSM_Connectio while (N6110_GetModel(phonemodel) != GE_NONE) sleep(1); - if (!strcmp(phonemodel,"NPE-3") || !strcmp(phonemodel,"NSE-5")) + if (!strcmp(phonemodel,"NPE-3") || !strcmp(phonemodel,"NSE-5") || + !strcmp(phonemodel,"NHM-3")) { GSM->Terminate(); @@ -426,7 +432,7 @@ GSM_Error GSM_Initialise(char *model, char *device, char *initlength, GSM_Connec case GCT_MBUS : Protocol = &MBUS_Functions; break; case GCT_Irda : Protocol = &FBUSIRDA_Functions;break; case GCT_AT : Protocol = &AT_Functions; break; - case GCT_Default : Protocol = NULL; break; + case GCT_FBUS3110: Protocol = &FBUS3110_Functions;break; } CurrentConnectionType=connection; connection2=connection; @@ -452,6 +458,13 @@ GSM_Error GSM_Initialise(char *model, char *device, char *initlength, GSM_Connec } #endif + if (CheckModel (N3110_Information, model, connection)) { + /* Set pointers to relevant addresses */ + GSM = &N3110_Functions; + GSM_Info = &N3110_Information; + GSM_LinkOK = &CurrentLinkOK; + found_match=true; + } if (CheckModel (N6110_Information, model, connection)) { /* Set pointers to relevant addresses */ GSM = &N6110_Functions; @@ -483,7 +496,7 @@ GSM_Error GSM_Initialise(char *model, char *device, char *initlength, GSM_Connec case GCT_MBUS : Protocol = &MBUS_Functions; break; case GCT_Irda : Protocol = &FBUSIRDA_Functions;break; case GCT_AT : Protocol = &AT_Functions; break; - case GCT_Default : Protocol = NULL; break; + case GCT_FBUS3110: Protocol = &FBUS3110_Functions;break; } } else return GE_NOTSUPPORTED; @@ -617,6 +630,7 @@ GSM_ConnectionType GetConnectionTypeFromString(char *Connection) { if (!strcmp(Connection, "infrared")) connection=GCT_Infrared; if (!strcmp(Connection, "mbus")) connection=GCT_MBUS; if (!strcmp(Connection, "dlr3")) connection=GCT_DLR3; + if (!strcmp(Connection, "fbus3110")) connection=GCT_FBUS3110; if (!strcmp(Connection, "at")) connection=GCT_AT; if (!strcmp(Connection, "tekram210"))connection=GCT_Tekram; diff --git a/common/gsm-networks.c b/common/gsm-networks.c index 4101a38..b36bcf5 100644 --- a/common/gsm-networks.c +++ b/common/gsm-networks.c @@ -269,49 +269,49 @@ GSM_Network GSM_Networks[] = { "400 01", "AZERCELL GSM" }, { "400 02", "Bakcell GSM 2000" }, - { "404 01", "AIRCELL"}, - { "404 02", "Evergrowth"}, - { "404 03", "Bharthi Telenet"}, - { "404 05", "Fascel"}, - { "404 07", "Tata Cell"}, //TATA Cellular + { "404 01", "AIRCELL"}, + { "404 02", "Evergrowth"}, + { "404 03", "Bharthi Telenet"}, + { "404 05", "Fascel"}, + { "404 07", "Tata Cell"}, //TATA Cellular { "404 08", "Koshika"}, - { "404 09", "Reliance"}, - { "404 10", "AIRTEL"}, //AirTel - { "404 11", "Essar"}, //Essar Cellphone - { "404 12", "Escotel"}, - { "404 14", "Spice"}, //Modicom - { "404 15", "AIRCELL"}, //Essar Cellphone - { "404 18", "Reliance"}, - { "404 19", "Escotel"}, - { "404 20", "Orange"}, //Max Touch - { "404 21", "BPL Mobile"}, //BPL - Mobile - { "404 22", "Birla AT&T"}, - { "404 24", "Birla AT&T"}, - { "404 26", "Koshika"}, - { "404 27", "BPL Mobile"}, //BPL USWEST Cellular - { "404 30", "Usha"}, //Command - { "404 31", "AIRCELL"}, //? - { "404 31", "Command"}, //? - { "404 32", "Koshika"}, - { "404 34", "Koshika"}, - { "404 36", "Reliance"}, - { "404 40", "SkyCell"}, + { "404 09", "Reliance"}, + { "404 10", "AIRTEL"}, //AirTel + { "404 11", "Essar"}, //Essar Cellphone + { "404 12", "Escotel"}, + { "404 14", "Spice"}, //Modicom + { "404 15", "AIRCELL"}, //Essar Cellphone + { "404 18", "Reliance"}, + { "404 19", "Escotel"}, + { "404 20", "Orange"}, //Max Touch + { "404 21", "BPL Mobile"}, //BPL - Mobile + { "404 22", "Birla AT&T"}, + { "404 24", "Birla AT&T"}, + { "404 26", "Koshika"}, + { "404 27", "BPL Mobile"}, //BPL USWEST Cellular + { "404 30", "Usha"}, //Command + { "404 31", "AIRCELL"}, //? + { "404 31", "Command"}, //? + { "404 32", "Koshika"}, + { "404 34", "Koshika"}, + { "404 36", "Reliance"}, + { "404 40", "SkyCell"}, { "404 41", "RPG"}, //RPG Cellular - { "404 42", "AIRCELL"}, //AIRCEL - { "404 43", "BPL Mobile"}, - { "404 44", "Spice"}, - { "404 45", "AIRTEL-blr"}, - { "404 46", "BPL Moibile"}, + { "404 42", "AIRCELL"}, //AIRCEL + { "404 43", "BPL Mobile"}, + { "404 44", "Spice"}, + { "404 45", "AIRTEL-blr"}, + { "404 46", "BPL Moibile"}, { "404 49", "AIRTEL"}, - { "404 50", "Reliance"}, + { "404 50", "Reliance"}, { "404 52", "Reliance"}, { "404 56", "Escotel"}, - { "404 60", "AIRCELL"}, + { "404 60", "AIRCELL"}, { "404 67", "Reliance"}, - { "404 70", "Hexacom"}, - { "404 78", "RPG"}, - { "404 85", "Reliance"}, - + { "404 70", "Hexacom"}, + { "404 78", "RPG"}, + { "404 85", "Reliance"}, + { "410 01", "Mobilink" }, { "413 02", "DIALOG GSM" }, { "415 01", "CELLIS" }, diff --git a/common/gsm-ringtones.c b/common/gsm-ringtones.c index 3db43b6..588ddad 100644 --- a/common/gsm-ringtones.c +++ b/common/gsm-ringtones.c @@ -223,62 +223,62 @@ u8 GSM_PackRingtone(GSM_Ringtone *ringtone, unsigned char *package, int *maxleng int DefNoteTempo=63; u8 DefNoteStyle=NaturalStyle; - int buffer[6]; /* Used to find default ringtone parameters */ - int i,j,k=0,thisnote,thisnotelong; + int buffer[6]; /* Used to find default ringtone parameters */ + int i,j,k=0,thisnote,thisnotelong; - /* Find the most frequently used duration and use this for the default */ - for (i=0;i<6;i++) buffer[i]=0; - for (i=0;iNrNotes;i++) { - switch (ringtone->notes[i].duration) { - case 192: buffer[0]++; break; - case 128: buffer[0]++; break; - case 96: buffer[1]++; break; - case 64: buffer[1]++; break; - case 48: buffer[2]++; break; - case 32: buffer[2]++; break; - case 24: buffer[3]++; break; - case 16: buffer[3]++; break; - case 12: buffer[4]++; break; - case 8: buffer[4]++; break; - case 6: buffer[5]++; break; - case 4: buffer[5]++; break; - } - } - - /* Now find the most frequently used */ - j=0; - for (i=0;i<6;i++) { - if (buffer[i]>j) { - k=i; - j=buffer[i]; - } - } - - /* Finally convert the default duration */ - switch (k) { - case 0: DefNoteDuration=128; break; - case 1: DefNoteDuration= 64; break; - case 2: DefNoteDuration= 32; break; - case 3: DefNoteDuration= 16; break; - case 4: DefNoteDuration= 8; break; - case 5: DefNoteDuration= 4; break; - default: DefNoteDuration= 16; break; - } - - /* Find the most frequently used scale and use this for the default */ - for (i=0;i<6;i++) buffer[i]=0; - for (i=0;iNrNotes;i++) { - if (ringtone->notes[i].note!=255) { - buffer[ringtone->notes[i].note/14]++; - } - } - j=0; - for (i=0;i<6;i++) { - if (buffer[i]>j) { - DefNoteScale=i; - j=buffer[i]; - } - } + /* Find the most frequently used duration and use this for the default */ + for (i=0;i<6;i++) buffer[i]=0; + for (i=0;iNrNotes;i++) { + switch (ringtone->notes[i].duration) { + case 192: buffer[0]++; break; + case 128: buffer[0]++; break; + case 96: buffer[1]++; break; + case 64: buffer[1]++; break; + case 48: buffer[2]++; break; + case 32: buffer[2]++; break; + case 24: buffer[3]++; break; + case 16: buffer[3]++; break; + case 12: buffer[4]++; break; + case 8: buffer[4]++; break; + case 6: buffer[5]++; break; + case 4: buffer[5]++; break; + } + } + + /* Now find the most frequently used */ + j=0; + for (i=0;i<6;i++) { + if (buffer[i]>j) { + k=i; + j=buffer[i]; + } + } + + /* Finally convert the default duration */ + switch (k) { + case 0: DefNoteDuration=128; break; + case 1: DefNoteDuration= 64; break; + case 2: DefNoteDuration= 32; break; + case 3: DefNoteDuration= 16; break; + case 4: DefNoteDuration= 8; break; + case 5: DefNoteDuration= 4; break; + default: DefNoteDuration= 16; break; + } + + /* Find the most frequently used scale and use this for the default */ + for (i=0;i<6;i++) buffer[i]=0; + for (i=0;iNrNotes;i++) { + if (ringtone->notes[i].note!=255) { + buffer[ringtone->notes[i].note/14]++; + } + } + j=0; + for (i=0;i<6;i++) { + if (buffer[i]>j) { + DefNoteScale=i; + j=buffer[i]; + } + } StartBit=BitPackByte(package, StartBit, CommandLength, 8); StartBit=BitPackByte(package, StartBit, RingingToneProgramming, 7); diff --git a/common/gsm-sms.c b/common/gsm-sms.c index 52020c1..9fbb114 100644 --- a/common/gsm-sms.c +++ b/common/gsm-sms.c @@ -730,6 +730,7 @@ GSM_Error GSM_EncodeETSISMSSubmitValidity(GSM_SMSMessage *SMS,GSM_ETSISMSMessage GSM_Error GSM_EncodeETSISMS(GSM_SMSMessage *SMS, GSM_ETSISMSMessage *ETSI, SMS_MessageType PDU, int *length) { int size=0; + GSM_Error error; ETSI->firstbyte=0; ETSI->TPPID=0; @@ -749,8 +750,10 @@ GSM_Error GSM_EncodeETSISMS(GSM_SMSMessage *SMS, GSM_ETSISMSMessage *ETSI, SMS_M /* Mask for request for delivery report from SMSC */ if (SMS->Type == GST_DR) ETSI->firstbyte |= 32; - GSM_EncodeETSISMSSubmitHeader(SMS, ETSI); - GSM_EncodeETSISMSSubmitValidity(SMS, ETSI); + error=GSM_EncodeETSISMSSubmitHeader(SMS, ETSI); + if (error!=GE_NONE) return error; + error=GSM_EncodeETSISMSSubmitValidity(SMS, ETSI); + if (error!=GE_NONE) return error; size=GSM_EncodeETSISMSSubmitData(SMS, ETSI); break; @@ -760,7 +763,8 @@ GSM_Error GSM_EncodeETSISMS(GSM_SMSMessage *SMS, GSM_ETSISMSMessage *ETSI, SMS_M /* Bits 1 and 0: 00. SMS-Deliver */ ETSI->firstbyte |= 0x00; - GSM_EncodeETSISMSSubmitHeader(SMS, ETSI); + error=GSM_EncodeETSISMSSubmitHeader(SMS, ETSI); + if (error!=GE_NONE) return error; GSM_EncodeSMSDateTime(&SMS->Time, ETSI->DeliveryDateTime); size=GSM_EncodeETSISMSSubmitData(SMS, ETSI); diff --git a/common/misc.c b/common/misc.c index b17a93e..46f8958 100644 --- a/common/misc.c +++ b/common/misc.c @@ -8,9 +8,9 @@ */ -#include -#include -#include +#include +#include +#include #ifndef WIN32 #include @@ -20,10 +20,10 @@ #include #include #include -#endif - -#include "misc.h" -#include "gsm-common.h" +#endif + +#include "misc.h" +#include "gsm-common.h" #ifndef HAVE_TIMEOPS @@ -153,88 +153,3 @@ void txhexdump(u16 MessageLength, u8 *MessageBuffer) fflush(stdout); } #endif - -#ifndef WIN32 - -#define max_buf_len 128 -#define lock_path "/var/lock/LCK.." - -/* Lock the device. Return allocated string with a lock name */ -char *lock_device(const char* port) -{ - char *lock_file = NULL; - char buffer[max_buf_len]; - char *aux = rindex(port, '/'); - int fd, len = strlen(aux) + strlen(lock_path); - - memset(buffer, 0, sizeof(buffer)); - lock_file = calloc(len + 1, 1); - if (!lock_file) { - fprintf(stderr, _("Cannot lock device\n")); - return NULL; - } - /* I think we don't need to use strncpy, as we should have enough - * buffer due to strlen results - */ - strcpy(lock_file, lock_path); - strcat(lock_file, aux); - - /* Check for the stale lockfile. - * The code taken from minicom by Miquel van Smoorenburg */ - if ((fd = open(lock_file, O_RDONLY)) >= 0) { - char buf[max_buf_len]; - int pid, n = 0; - - n = read(fd, buf, sizeof(buf) - 1); - close(fd); - if (n > 0) { - pid = -1; - if (n == 4) - /* Kermit-style lockfile. */ - pid = *(int *)buf; - else { - /* Ascii lockfile. */ - buf[n] = 0; - sscanf(buf, "%d", &pid); - } - if (pid > 0 && kill((pid_t)pid, 0) < 0 && errno == ESRCH) { - fprintf(stderr, _("Lockfile is stale. Overriding it..\n")); - sleep(1); - unlink(lock_file); - } else - n = 0; - } - if (n == 0) { - free(lock_file); - fprintf(stderr, _("Device is already locked.\n")); - return NULL; - } - } - - /* Try to create a new file, with 0644 mode */ - fd = open(lock_file, O_CREAT | O_EXCL, 0644); - if (fd == -1) { - free(lock_file); - fprintf(stderr, _("Cannot lock device\n")); - return NULL; - } - sprintf(buffer, "%10ld gnokii\n", (long)getpid()); - write(fd, buffer, strlen(buffer)); - close(fd); - return lock_file; -} - -/* Removes lock and frees memory */ -bool unlock_device(char *lock_file) -{ - int err; - - if (!lock_file) { - fprintf(stderr, _("Cannot unlock device\n")); - return false; - } - err = unlink(lock_file); - free(lock_file); - return (err + 1); -} -#endif /* WIN32 */ diff --git a/gnokii/gnokii.c b/gnokii/gnokii.c index c8db700..87943ec 100644 --- a/gnokii/gnokii.c +++ b/gnokii/gnokii.c @@ -260,6 +260,7 @@ char *print_error(GSM_Error e) case GE_INVALIDBOOKMARKLOCATION: return "Invalid or empty WAP bookmark location"; case GE_INSIDESETTINGSMENU: return "Inside WAP Settings menu. Please leave it and try again"; case GE_INVALIDSETTINGSLOCATION: return "Invalid or empty WAP settings location"; + case GE_EMPTYSMSC: return "Empty SMSC number. Use --smsc"; default: return "Unknown error."; } } @@ -453,8 +454,8 @@ int GSM_SendMultiPartSMSOnConsole(GSM_MultiSMSMessage *MultiSMS, int argnum, int int w,i; struct option options[] = { - { "smscno", required_argument, NULL, '1'}, - { "smsc", required_argument, NULL, '2'}, + { "smscno", required_argument, NULL, '2'}, + { "smsc", required_argument, NULL, '1'}, { "name", required_argument, NULL, '3'}, { "unicode", no_argument, NULL, '4'}, { "profilestyle", no_argument, NULL, '5'}, @@ -527,7 +528,7 @@ int GSM_SendMultiPartSMSOnConsole(GSM_MultiSMSMessage *MultiSMS, int argnum, int if (error == GE_SMSSENDOK) { fprintf(stdout, _("SMS %i/%i sent OK !\n"),w+1,MultiSMS->number); } else { - fprintf(stdout, _("SMS %i/%i, sending failed (error=%d)\n"),w+1,MultiSMS->number, error); + fprintf(stdout, _("SMS %i/%i, sending failed (%d, %s)\n"),w+1,MultiSMS->number, error,print_error(error)); } } @@ -545,8 +546,8 @@ int GSM_SaveMultiPartSMSOnConsole(GSM_MultiSMSMessage *MultiSMS, int argnum, int GSM_SMSMessage SMSold; struct option options[] = { - { "smscno", required_argument, NULL, '1'}, - { "smsc", required_argument, NULL, '2'}, + { "smscno", required_argument, NULL, '2'}, + { "smsc", required_argument, NULL, '1'}, { "name", required_argument, NULL, '3'}, { "unicode", no_argument, NULL, '4'}, { "profilestyle", no_argument, NULL, '5'}, @@ -655,7 +656,7 @@ int GSM_SaveMultiPartSMSOnConsole(GSM_MultiSMSMessage *MultiSMS, int argnum, int if (error == GE_NONE) fprintf(stdout, _("SMS %i/%i saved at location %i !\n"),w+1,MultiSMS->number,MultiSMS->SMS[w].MessageNumber); else - fprintf(stdout, _("SMS %i/%i saving failed (error=%d, location=%i)\n"), w+1, MultiSMS->number, error,MultiSMS->SMS[w].Location); + fprintf(stdout, _("SMS %i/%i saving failed (%d, %s, location=%i)\n"), w+1, MultiSMS->number,error,print_error(error),MultiSMS->SMS[w].Location); } GSM->Terminate(); @@ -1642,8 +1643,8 @@ int sendsms(int argc, char *argv[]) GSM_UDH SMSUDHType=GSM_NoUDH; struct option options[] = { - { "smscno", required_argument, NULL, '1'}, - { "smsc", required_argument, NULL, '2'}, + { "smscno", required_argument, NULL, '2'}, + { "smsc", required_argument, NULL, '1'}, { "long", required_argument, NULL, '3'}, { "enablevoice", no_argument, NULL, '4'}, { "disablevoice", no_argument, NULL, '5'}, @@ -1828,8 +1829,8 @@ int savesms(int argc, char *argv[]) bool interactive=false; struct option options[] = { - { "smscno", required_argument, NULL, '1'}, - { "smsc", required_argument, NULL, '2'}, + { "smscno", required_argument, NULL, '2'}, + { "smsc", required_argument, NULL, '1'}, { "long", required_argument, NULL, '3'}, { "enablevoice", no_argument, NULL, '4'}, { "disablevoice", no_argument, NULL, '5'}, @@ -7651,32 +7652,32 @@ int binringtoneconvert(int argc, char *argv[]) w=w*2; if (w>z && (w/2)<=z) { switch (m) { - case 1:fprintf(file,_("16"));break; - case 2:fprintf(file,_("8"));break; - case 3:fprintf(file,_("4"));break; - case 4:fprintf(file,_("2"));break; - case 5:fprintf(file,_("1"));break; + case 1:fprintf(file,_("16"));break; + case 2:fprintf(file,_("8"));break; + case 3:fprintf(file,_("4"));break; + case 4:fprintf(file,_("2"));break; + case 5:fprintf(file,_("1"));break; } break; } } if (z>w) fprintf(file,_("1")); pause=false; - switch (GSM_GetNote(j)) { - case Note_C :fprintf(file,_("c"));break; - case Note_Cis:fprintf(file,_("c#"));break; - case Note_D :fprintf(file,_("d"));break; - case Note_Dis:fprintf(file,_("d#"));break; - case Note_E :fprintf(file,_("e"));break; - case Note_F :fprintf(file,_("f"));break; - case Note_Fis:fprintf(file,_("f#"));break; - case Note_G :fprintf(file,_("g"));break; - case Note_Gis:fprintf(file,_("g#"));break; - case Note_A :fprintf(file,_("a"));break; - case Note_Ais:fprintf(file,_("a#"));break; - case Note_H :fprintf(file,_("h"));break; - default :pause=true;fprintf(file,_("p"));break; //Pause ? - } + switch (GSM_GetNote(j)) { + case Note_C :fprintf(file,_("c"));break; + case Note_Cis:fprintf(file,_("c#"));break; + case Note_D :fprintf(file,_("d"));break; + case Note_Dis:fprintf(file,_("d#"));break; + case Note_E :fprintf(file,_("e"));break; + case Note_F :fprintf(file,_("f"));break; + case Note_Fis:fprintf(file,_("f#"));break; + case Note_G :fprintf(file,_("g"));break; + case Note_Gis:fprintf(file,_("g#"));break; + case Note_A :fprintf(file,_("a"));break; + case Note_Ais:fprintf(file,_("a#"));break; + case Note_H :fprintf(file,_("h"));break; + default :pause=true;fprintf(file,_("p"));break; //Pause ? + } w=deflen*1.5; for (m=0;m<6;m++) { w=w*2; @@ -7815,11 +7816,11 @@ int setsimlock() fprintf(stderr,_("Error getting simlock info\n"));GSM->Terminate();return -1; } /* Opening all locks (we must check, if we can open them) */ - NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer0); - openbuffer[4]=1;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=2;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=4;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=8;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); + NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer0); + openbuffer[4]=1;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=2;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=4;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=8;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); if (GSM->SimlockInfo(&siml)!=GE_NONE) { fprintf(stderr,_("Error getting simlock info\n"));GSM->Terminate();return -1; } @@ -7868,13 +7869,13 @@ int setsimlock() } /* Closing simlock with given values */ closebuffer[4]=1+2+4+8; - NULL_SendMessageSequence(50, &CurrentMagicError, 20, 0x40,closebuffer); + NULL_SendMessageSequence (50, &CurrentMagicError, 20, 0x40,closebuffer); /* Opening all locks */ - NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer0); - openbuffer[4]=1;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=2;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=4;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); - openbuffer[4]=8;NULL_SendMessageSequence(50, &CurrentMagicError, 10, 0x40,openbuffer); + NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer0); + openbuffer[4]=1;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=2;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=4;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); + openbuffer[4]=8;NULL_SendMessageSequence (50, &CurrentMagicError, 10, 0x40,openbuffer); GSM->Reset(0x03); GSM->Terminate(); return 0; @@ -7974,7 +7975,7 @@ int geteeprom() if ((i/256)!=((i-1)/256)) fprintf(stderr,_(".")); - if (NULL_SendMessageSequence(50, &CurrentMagicError, 9, 0x40,buffer)!=GE_NONE) break; + if (NULL_SendMessageSequence(50, &CurrentMagicError, 9, 0x40,buffer)!=GE_NONE) break; i=i+0x10; } diff --git a/include/gsm-api.h b/include/gsm-api.h index 7f45115..fa655b4 100644 --- a/include/gsm-api.h +++ b/include/gsm-api.h @@ -227,19 +227,14 @@ typedef struct { typedef struct { - char *FBUSModels; /* Models covered by this type, pipe '|' delimited. */ - - char *MBUSModels; /* Models covered by this type, pipe '|' delimited. */ - - char *InfraredModels; /* Models covered by this type, pipe '|' delimited. */ - - char *DLR3Models; /* Models covered by this type, pipe '|' delimited. */ - - char *ATModels; /* Models covered by this type, pipe '|' delimited. */ - - char *IrdaModels; /* Models covered by this type, pipe '|' delimited. */ - - char *TekramModels; /* Models covered by this type, pipe '|' delimited. */ + char *FBUSModels; /* Models covered by this type, pipe '|' delimited. */ + char *MBUSModels; /* Models covered by this type, pipe '|' delimited. */ + char *InfraredModels; /* Models covered by this type, pipe '|' delimited. */ + char *DLR3Models; /* Models covered by this type, pipe '|' delimited. */ + char *ATModels; /* Models covered by this type, pipe '|' delimited. */ + char *IrdaModels; /* Models covered by this type, pipe '|' delimited. */ + char *TekramModels; /* Models covered by this type, pipe '|' delimited. */ + char *FBUS3110Models; /* Models covered by this type, pipe '|' delimited. */ /* Minimum and maximum levels for RF signal strength. Units are as per the setting of RFLevelUnits. The setting of RFLevelUnits indicates the @@ -444,7 +439,7 @@ bool CheckModel (GSM_Information InfoToCheck, char *model, GSM_ConnectionType co char *GetMygnokiiVersion(); typedef enum { - F_CAL61=0,/*Calendar in 6110 style - 4 types,...*/ + F_CAL61=1,/*Calendar in 6110 style - 4 types,...*/ F_CAL33, /*Calendar in 3310 style - 10 reminders, Unicode, 3 coding types*/ F_CAL71, /*Calendar in 7110 style - 4 types, recurrance, etc.*/ @@ -456,8 +451,8 @@ typedef enum { F_DATA61, /*We can make data calls using gnokiid. Like in 6110*/ F_DATA71, /*Datacalls using AT commands*/ - F_SMS, /*SMS with Inbox, Outbox*/ - F_SMS71, /*SMS with SMS folders like in 7110*/ /*10*/ + F_SMS, /*SMS with Inbox, Outbox*/ /*10*/ + F_SMS71, /*SMS with SMS folders like in 7110*/ F_AUTH, /*We can make authentication and have "Accessory connected" like in 6110*/ F_NETMON, /*Netmonitor available*/ @@ -467,9 +462,9 @@ typedef enum { F_SPEED, /*We can handle speed dials*/ F_SCRSAV, /*We have screen savers*/ F_DTMF, /*We can handle DTMF sequences*/ - F_NOPOWER,/*We must get power/battery info from netmonitor*/ + F_NOPOWER,/*We must get power/battery info from netmonitor*/ /*20*/ - F_STANIM, /*Startup logo animated or static*/ /*20*/ + F_STANIM, /*Startup logo animated or static*/ F_STA , /*Startup logo static*/ F_STA62 , /*Startup logo static size 6210*/ F_STA71 , /*Startup logo static size 7110*/ @@ -481,7 +476,7 @@ typedef enum { F_RING_SM,/*Binary ringtone in Smart Messaging*/ F_RINGBIN,/*Binary ringtone in binary format*/ - F_WAP /*WAP functions available*/ + F_WAP /*WAP functions available*/ /*30*/ } feat_index; typedef enum { diff --git a/include/gsm-common.h b/include/gsm-common.h index a87900f..9433499 100644 --- a/include/gsm-common.h +++ b/include/gsm-common.h @@ -69,8 +69,8 @@ #define GSM_MAX_REVISION_LENGTH (20) #define GSM_MAX_MODEL_LENGTH (10) -/* In 6210 test 57 there seems to be 75 chars */ -#define NM_MAX_SCREEN_WIDTH 75 +/* In 6210 test 57 there seems to be 75 chars */ +#define NM_MAX_SCREEN_WIDTH 75 /* Power source types */ typedef enum { @@ -314,6 +314,7 @@ typedef enum { GE_INVALIDBOOKMARKLOCATION, GE_INSIDESETTINGSMENU, GE_INVALIDSETTINGSLOCATION, + GE_EMPTYSMSC, /* The following are here in anticipation of data call requirements. */ diff --git a/xgnokii/xgnokii_sms.c b/xgnokii/xgnokii_sms.c index a9726b9..d5da1f4 100644 --- a/xgnokii/xgnokii_sms.c +++ b/xgnokii/xgnokii_sms.c @@ -1005,7 +1005,7 @@ static void SendSMS (void) if (GTK_TOGGLE_BUTTON (sendSMS.report)->active) Multisms.SMS[j].Type = GST_DR; - if (GTK_TOGGLE_BUTTON (sendSMS.class)->active) Multisms.SMS[j].Class = 0; + if (GTK_TOGGLE_BUTTON (sendSMS.class)->active) Multisms.SMS[j].Class = 0; Multisms.SMS[j].Validity = Multisms.SMS[j].MessageCenter.Validity; @@ -1226,9 +1226,9 @@ static void CreateSMSSendWindow (void) gtk_box_pack_start (GTK_BOX (vbox), sendSMS.longSMS, FALSE, FALSE, 3); gtk_widget_show (sendSMS.longSMS); - sendSMS.class = gtk_check_button_new_with_label (_("Send as Flash SMS (Class 0)")); - gtk_box_pack_start (GTK_BOX (vbox), sendSMS.class, FALSE, FALSE, 3); - gtk_widget_show (sendSMS.class); + sendSMS.class = gtk_check_button_new_with_label (_("Send as Flash SMS (Class 0)")); + gtk_box_pack_start (GTK_BOX (vbox), sendSMS.class, FALSE, FALSE, 3); + gtk_widget_show (sendSMS.class); label = gtk_label_new (_("SMS Center:")); gtk_box_pack_start (GTK_BOX (vbox), label, FALSE, FALSE, 1); -- 1.8.3.1